Mercurial > projects > ldc
changeset 666:0d934394ada1
Implement BoolExp.
author | Christian Kamm <kamm incasoftware de> |
---|---|
date | Tue, 07 Oct 2008 18:41:00 +0200 |
parents | d8a1481eaa0c |
children | 9c48213cfd96 |
files | gen/toir.cpp |
diffstat | 1 files changed, 7 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/gen/toir.cpp Mon Oct 06 22:56:54 2008 +0200 +++ b/gen/toir.cpp Tue Oct 07 18:41:00 2008 +0200 @@ -2431,13 +2431,19 @@ ////////////////////////////////////////////////////////////////////////////////////////// +DValue* BoolExp::toElem(IRState* p) +{ + return new DImValue(type, DtoBoolean(loc, e1->toElem(p))); +} + +////////////////////////////////////////////////////////////////////////////////////////// + #define STUB(x) DValue *x::toElem(IRState * p) {error("Exp type "#x" not implemented: %s", toChars()); fatal(); return 0; } STUB(Expression); STUB(DotTypeExp); STUB(TypeDotIdExp); STUB(ScopeExp); STUB(TypeExp); -STUB(BoolExp); STUB(TupleExp); #define CONSTSTUB(x) LLConstant* x::toConstElem(IRState * p) {error("const Exp type "#x" not implemented: '%s' type: '%s'", toChars(), type->toChars()); fatal(); return NULL; }