mirror of
https://github.com/dlang/phobos.git
synced 2025-04-28 06:00:35 +03:00
Fixes Issue 9373 - Add deprecation messages to Phobos.
This commit is contained in:
parent
c89b21e38f
commit
aaa6854eb7
8 changed files with 44 additions and 53 deletions
|
@ -562,7 +562,8 @@ template enforceEx(E)
|
|||
If $(D !!value) is $(D true), $(D value) is returned. Otherwise,
|
||||
$(D new E(msg)) is thrown.
|
||||
+/
|
||||
deprecated template enforceEx(E)
|
||||
deprecated("Please use the version of enforceEx which takes an exception that constructs with new E(msg, file, line).")
|
||||
template enforceEx(E)
|
||||
if (is(typeof(new E(""))) && !is(typeof(new E("", __FILE__, __LINE__))) && !is(typeof(new E(__FILE__, __LINE__))))
|
||||
{
|
||||
T enforceEx(T)(T value, lazy string msg = "")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue