summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/conditional.c
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-07-13 20:18:44 +0000
committerChris Lattner <sabre@nondot.org>2007-07-13 20:18:44 +0000
commit91dacfec856d927314ee026dbe24bc2374a3e03c (patch)
tree6e5e675c39d33ce4848f3422d4df3b114690f059 /clang/test/CodeGen/conditional.c
parent10835d9c67081221e21aeeb324b4452517984ca8 (diff)
downloadbcm5719-llvm-91dacfec856d927314ee026dbe24bc2374a3e03c.tar.gz
bcm5719-llvm-91dacfec856d927314ee026dbe24bc2374a3e03c.zip
Check in these testcases.
llvm-svn: 39829
Diffstat (limited to 'clang/test/CodeGen/conditional.c')
-rw-r--r--clang/test/CodeGen/conditional.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/test/CodeGen/conditional.c b/clang/test/CodeGen/conditional.c
new file mode 100644
index 00000000000..ef3283d1d49
--- /dev/null
+++ b/clang/test/CodeGen/conditional.c
@@ -0,0 +1,12 @@
+// RUN: clang -emit-llvm %s
+
+float test1(int cond, float a, float b)
+{
+ return cond ? a : b;
+}
+/* this will fail for now...
+double test2(int cond, float a, double b)
+{
+ return cond ? a : b;
+}
+*/
OpenPOWER on IntegriCloud