Mercurial > projects > ldc
diff gen/toir.cpp @ 464:e381e082d5cb
Fixed problem with using the variable names _arguments and _argptr in non D-style vararg functions.
Fixed problem with compiling with LLVM 2.3
author | Tomas Lindquist Olsen <tomas.l.olsen@gmail.com> |
---|---|
date | Sun, 03 Aug 2008 16:10:00 +0200 |
parents | 3a5d6ff8c70f |
children | 261b05cf4d1c |
line wrap: on
line diff
--- a/gen/toir.cpp Sat Aug 02 22:54:46 2008 +0200 +++ b/gen/toir.cpp Sun Aug 03 16:10:00 2008 +0200 @@ -60,19 +60,17 @@ Logger::println("VarDeclaration %s", vd->toChars()); // _arguments - if (vd->ident == Id::_arguments) + if (vd->ident == Id::_arguments && p->func()->_arguments) { Logger::println("Id::_arguments"); LLValue* v = p->func()->_arguments; - assert(v); return new DVarValue(type, vd, v, true); } // _argptr - else if (vd->ident == Id::_argptr) + else if (vd->ident == Id::_argptr && p->func()->_argptr) { Logger::println("Id::_argptr"); LLValue* v = p->func()->_argptr; - assert(v); return new DVarValue(type, vd, v, true); } // _dollar