[phobos] D2's std.exception
Jonathan M Davis
jmdavisProg at gmx.com
Thu Mar 17 16:35:30 PDT 2011
On Thursday, March 17, 2011 16:15:46 Walter Bright wrote:
> Looking over it, the old license needs to be removed.
>
> The documentation for enforce() should clearly state that it is not to be
> used for bug detection (use contracts and asserts instead).
Pull request #12 on Phobos ( https://github.com/D-Programming-
Language/phobos/pull/12 ) fixes the license, and I think that it tweaks enforces
documentation ,but it doesn't try and make it clear about it not being for bug
detection. But considering that that is a really an issue of exceptions vs
assertions, rather than really an issue of enforce vs assert, I'm not sure how
much changing the documentation would help. But then again, I do have a clear
distinction betwen exceptions and assertions in my mind and understand what
enforce is doing, so maybe adding something to enforce's documentation would
help.
- Jonathan M Davis
More information about the phobos
mailing list