# HG changeset patch # User Christian Kamm # Date 1223397660 -7200 # Node ID 0d934394ada13c11f069df4c2c160d73a03d66ed # Parent d8a1481eaa0c59c0b92513f17fb9ae87c77c0eac Implement BoolExp. diff -r d8a1481eaa0c -r 0d934394ada1 gen/toir.cpp --- 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; }