# HG changeset patch # User Tomas Lindquist Olsen # Date 1217863933 -7200 # Node ID e19e201031199bc7a932ac6ef84b9d117bb60b4f # Parent 5e9883a7f9a5014133850a8225113c69232440df Changed DMD to make a copy of the TypeFunction in DelegateExp. diff -r 5e9883a7f9a5 -r e19e20103119 dmd/expression.c --- a/dmd/expression.c Mon Aug 04 03:40:08 2008 +0200 +++ b/dmd/expression.c Mon Aug 04 17:32:13 2008 +0200 @@ -5373,7 +5373,8 @@ if (!type) { e1 = e1->semantic(sc); - type = new TypeDelegate(func->type); + // LLVMDC we need a copy as we store the LLVM tpye in TypeFunction, and delegate/members have different types for 'this' + type = new TypeDelegate(func->type->syntaxCopy()); type = type->semantic(loc, sc); AggregateDeclaration *ad = func->toParent()->isAggregateDeclaration(); if (func->needThis())