From d24592b3e75d8755a5b02e7579bae0a55e039a35 Mon Sep 17 00:00:00 2001 From: David Nadlinger Date: Sat, 2 Jun 2012 19:21:13 +0200 Subject: [PATCH] Fix #77 - LDC1 fails to compile tango.io.vfs.ZipFolder. I think the same rewrite for contract this should be valid in D1 - if I missed something crucial, feel free to revert. --- gen/toir.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/gen/toir.cpp b/gen/toir.cpp index e9c92d92..636e319b 100644 --- a/gen/toir.cpp +++ b/gen/toir.cpp @@ -1479,15 +1479,12 @@ DValue* ThisExp::toElem(IRState* p) if (VarDeclaration* vd = var->isVarDeclaration()) { LLValue* v; Dsymbol* vdparent = vd->toParent2(); -#if DMDV2 Identifier *ident = p->func()->decl->ident; if (ident == Id::ensure || ident == Id::require) { Logger::println("contract this exp"); v = p->func()->nestArg; v = DtoBitCast(v, DtoType(type)->getPointerTo()); - } else -#endif - if (vdparent != p->func()->decl) { + } else if (vdparent != p->func()->decl) { Logger::println("nested this exp"); #if STRUCTTHISREF return DtoNestedVariable(loc, type, vd, type->ty == Tstruct);