On 29/08/13 16:13, John Colvin wrote: > struct Limited(T, T lower, T upper) > { > T _t; > mixin Proxy!_t; //Limited acts as T (almost) > invariant() > { > enforce(_t >= lower && _t <= upper); > } > this(T t) > { > _t = t; > } > } Is the invariant() not going to be stripped out at compile time if you use -release ?