Is this a bug in iota?

Jonathan M Davis jmdavisProg at gmx.com
Wed Apr 18 23:02:12 PDT 2012


On Thursday, April 19, 2012 05:45:54 Brad Anderson wrote:
> Doing this same thing to a slice of an array does throw a Range
> Violation exception in release (and asserts in debug).

That's impossible for a library to do. There is no way to version code on 
whether it's in release mode or not. Only the compiler controls that. So, you 
can use assertions, which will then be around in non-release mode but not 
release mode, but you can't do anything which will be around in non-release 
mode and not release mode.

The closest thing is -debug, but that's _completely_ different. It just enables 
debug blocks.

- Jonathan M Davis


More information about the Digitalmars-d-learn mailing list