Mercurial > projects > ldc
diff gen/complex.cpp @ 778:4adf0f742896
Get rid of DtoBoolean - use DtoCast(... Type::tbool) instead.
Fixed some casts to bool that were using truncation.
author | Christian Kamm <kamm incasoftware de> |
---|---|
date | Sat, 22 Nov 2008 18:35:52 +0100 |
parents | 4ac97ec7c18e |
children | 3cf0066e6faf |
line wrap: on
line diff
--- a/gen/complex.cpp Sat Nov 22 13:41:36 2008 +0100 +++ b/gen/complex.cpp Sat Nov 22 18:35:52 2008 +0100 @@ -454,6 +454,9 @@ DImValue* re = new DImValue(to, repart); return DtoCastFloat(loc, re, to); } + else if (to->ty == Tbool) { + return new DImValue(_to, DtoComplexEquals(loc, TOKnotequal, val, DtoNullValue(vty))); + } else assert(0); }