Merge pull request #6184 from wilzbach/enforce-docs

Expose the enforce overload on the docs
merged-on-behalf-of: Jack Stouffer <jack@jackstouffer.com>
This commit is contained in:
The Dlang Bot 2018-02-21 17:50:04 +01:00 committed by GitHub
commit d17a195abc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -388,7 +388,7 @@ void assertThrown(T : Throwable = Exception, E)
template enforce(E : Throwable = Exception)
if (is(typeof(new E("", __FILE__, __LINE__)) : Throwable) || is(typeof(new E(__FILE__, __LINE__)) : Throwable))
{
///
T enforce(T)(T value, lazy const(char)[] msg = null,
string file = __FILE__, size_t line = __LINE__)
if (is(typeof({ if (!value) {} })))