[llvm-commits] CVS: llvm/lib/AsmParser/llvmAsmParser.y
Chris Lattner
lattner at cs.uiuc.edu
Fri Sep 13 17:30:30 PDT 2002
Changes in directory llvm/lib/AsmParser:
llvmAsmParser.y updated: 1.92 -> 1.93
---
Log message:
Change the MallocInst & AllocaInst ctors to take the allocated type, not the
pointer type returned.
---
Diffs of the changes:
Index: llvm/lib/AsmParser/llvmAsmParser.y
diff -u llvm/lib/AsmParser/llvmAsmParser.y:1.92 llvm/lib/AsmParser/llvmAsmParser.y:1.93
--- llvm/lib/AsmParser/llvmAsmParser.y:1.92 Tue Sep 10 20:17:27 2002
+++ llvm/lib/AsmParser/llvmAsmParser.y Fri Sep 13 17:28:45 2002
@@ -1630,22 +1630,19 @@
};
MemoryInst : MALLOC Types {
- $$ = new MallocInst(PointerType::get(*$2));
+ $$ = new MallocInst(*$2);
delete $2;
}
| MALLOC Types ',' UINT ValueRef {
- const Type *Ty = PointerType::get(*$2);
- $$ = new MallocInst(Ty, getVal($4, $5));
+ $$ = new MallocInst(*$2, getVal($4, $5));
delete $2;
}
| ALLOCA Types {
- $$ = new AllocaInst(PointerType::get(*$2));
+ $$ = new AllocaInst(*$2);
delete $2;
}
| ALLOCA Types ',' UINT ValueRef {
- const Type *Ty = PointerType::get(*$2);
- Value *ArrSize = getVal($4, $5);
- $$ = new AllocaInst(Ty, ArrSize);
+ $$ = new AllocaInst(*$2, getVal($4, $5));
delete $2;
}
| FREE ResolvedVal {
More information about the llvm-commits
mailing list