On Friday, 2 November 2018 at 16:41:32 UTC, Stefan Koch wrote:
Which phobos functions are used in dmd?
there _should_ be none!

I think I didn't phrase the title correctly:

I'm using dmd as compiler and want to activate the contracts of phobos functions. For example there's a phobos function std.bitmanip.opIndex implemented like this:

bool opIndex(size_t i) const @nogc pure nothrow
    in {
        assert(i < _len);
    }
    do {
        return cast(bool) bt(_ptr, i);
    }

and when I call this function from my code I want the pre contract to be checked (assert(i < _len)

Reply via email to