[llvm-commits] CVS: llvm/test/Regression/C++Frontend/2003-11-18-MemberInitializationCasting.cpp.tr
Chris Lattner
lattner at cs.uiuc.edu
Tue Nov 18 15:07:05 PST 2003
Changes in directory llvm/test/Regression/C++Frontend:
2003-11-18-MemberInitializationCasting.cpp.tr added (r1.1)
---
Log message:
new testcase for PR126
---
Diffs of the changes: (+13 -0)
Index: llvm/test/Regression/C++Frontend/2003-11-18-MemberInitializationCasting.cpp.tr
diff -c /dev/null llvm/test/Regression/C++Frontend/2003-11-18-MemberInitializationCasting.cpp.tr:1.1
*** /dev/null Tue Nov 18 15:06:05 2003
--- llvm/test/Regression/C++Frontend/2003-11-18-MemberInitializationCasting.cpp.tr Tue Nov 18 15:05:55 2003
***************
*** 0 ****
--- 1,13 ----
+ // RUN: %llvmgcc -xc++ -S -o - %s | not grep ' cast '
+
+ struct A {
+ A() : i(0) {}
+ int getI() {return i;}
+ int i;
+ };
+
+ int f(int j)
+ {
+ A a;
+ return j+a.getI();
+ }
More information about the llvm-commits
mailing list