[LLVMbugs] [Bug 148] [llvmg++] Front-end attempts to return structure by value
bugzilla-daemon at zion.cs.uiuc.edu
bugzilla-daemon at zion.cs.uiuc.edu
Tue Nov 25 00:48:06 PST 2003
http://llvm.cs.uiuc.edu/bugs/show_bug.cgi?id=148
sabre at nondot.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
------- Additional Comments From sabre at nondot.org 2003-11-25 02:48 -------
Fixed.
Testcase here: 2003-11-25-ReturningOpaqueByValue.cpp
The patch:
$ diff -u llvm-types.c~ llvm-types.c
--- llvm-types.c~ 2003-11-19 18:59:34.000000000 -0600
+++ llvm-types.c 2003-11-25 02:41:55.000000000 -0600
@@ -874,7 +874,7 @@
* returning void and taking struct argument as it's first
* parameter.
*/
- if (RetType->ID == StructTyID) {
+ if (RetType->ID == StructTyID || RetType->ID == OpaqueTyID) {
FirstArgTy = llvm_type_get_pointer(RetType);
NumArgs++;
RetType = VoidTy;
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
More information about the llvm-bugs
mailing list