Mercurial > projects > ldc
diff gen/tollvm.c @ 18:c05ef76f1c20 trunk
[svn r22] * Forgot to add std.stdio
author | lindquist |
---|---|
date | Thu, 04 Oct 2007 01:47:53 +0200 |
parents | d3ee9efe20e2 |
children | 8d45266bbabe |
line wrap: on
line diff
--- a/gen/tollvm.c Wed Oct 03 06:14:41 2007 +0200 +++ b/gen/tollvm.c Thu Oct 04 01:47:53 2007 +0200 @@ -891,12 +891,15 @@ assert(f != 0); if (fdecl->llvmValue != 0) { - assert(llvm::isa<llvm::Function>(fdecl->llvmValue)); + if (!llvm::isa<llvm::Function>(fdecl->llvmValue)) + { + Logger::cout() << *fdecl->llvmValue << '\n'; + assert(0); + } return llvm::cast<llvm::Function>(fdecl->llvmValue); } - static int fdi = 0; - Logger::print("FuncDeclaration::toObjFile(%d,%s): %s\n", fdi++, fdecl->needThis()?"this":"static",fdecl->toChars()); + Logger::print("FuncDeclaration::toObjFile(%s): %s\n", fdecl->needThis()?"this":"static",fdecl->toChars()); LOG_SCOPE; if (fdecl->llvmInternal == LLVMintrinsic && fdecl->fbody) {