Improving assert-printing in DMD
Nordlöw via Digitalmars-d
digitalmars-d at puremagic.com
Mon Oct 26 12:17:11 PDT 2015
On Monday, 26 October 2015 at 17:36:37 UTC, Nordlöw wrote:
> Eventhough compiler rewrites
>
> X != Y
>
> into
>
> !(X == Y)
>
> and we cannot explicit overload opBinary!"!=" there is nothing
> stopping us allowing
>
> onBinaryAssert!"!="
>
> in the rewriter.
Correction:
there is nothing stopping us from allowing
onAssertFailed!"!="
to be defined as long as the compiler lowering logic can do the
correct rewrite.
More information about the Digitalmars-d
mailing list