Mercurial > projects > ldc
comparison gen/functions.cpp @ 457:d82ebdba4191
Fixed debug info and lazy arguments.
author | Tomas Lindquist Olsen <tomas.l.olsen@gmail.com> |
---|---|
date | Sat, 02 Aug 2008 21:51:49 +0200 |
parents | d3d3519b72e8 |
children | 45a67b6f1310 |
comparison
equal
deleted
inserted
replaced
456:b975f29b7256 | 457:d82ebdba4191 |
---|---|
593 { | 593 { |
594 Dsymbol* argsym = (Dsymbol*)fd->parameters->data[i]; | 594 Dsymbol* argsym = (Dsymbol*)fd->parameters->data[i]; |
595 VarDeclaration* vd = argsym->isVarDeclaration(); | 595 VarDeclaration* vd = argsym->isVarDeclaration(); |
596 assert(vd); | 596 assert(vd); |
597 | 597 |
598 bool refoutlazy = vd->storage_class & (STCref | STCout | STClazy); | |
599 | |
598 // FIXME: llvm seems to want an alloca/byval for debug info | 600 // FIXME: llvm seems to want an alloca/byval for debug info |
599 if (!vd->needsStorage || vd->nestedref || vd->isRef() || vd->isOut()) | 601 if (!vd->needsStorage || vd->nestedref || refoutlazy) |
600 { | 602 { |
601 Logger::println("skipping arg storage for (%s) %s ", vd->loc.toChars(), vd->toChars()); | 603 Logger::println("skipping arg storage for (%s) %s ", vd->loc.toChars(), vd->toChars()); |
602 continue; | 604 continue; |
603 } | 605 } |
604 // static array params don't support debug info it seems | 606 // static array params don't support debug info it seems |