http://llvm.org/bugs/show_bug.cgi?id=4213

           Summary: Cannot create call to void function using C++ API
           Product: libraries
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Common Code Generator Code
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected]


When attempting to create a call to a function with a return type of
Type::VoidTy using the C++ API, I get the following assertion failure:

"molc: Value.cpp:182: void llvm::Value::setName(const char*, unsigned int):
Assertion `getType() != Type::VoidTy && "Cannot assign a name to void values!"'
failed."

This appears to be because the CallInst class ultimately is derived from Value.
 The type that is passed to the Value constructor is the return type of the
called function.  The CallInst constructor then calls setName(), triggering the
assert.


-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to