summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2013-02-24 09:01:28 +0000
committerGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2013-02-24 09:01:28 +0000
commit202bc495442a1a8fa184b73ac0063bdbbbcdf846 (patch)
tree46c6920201b823bf47252bc52864b0bf60f3233e /test
parentf774d5f2d604f747e72e2d3bb56cc3f90090e2dd (diff)
Constant propagation within __builtin_annot.
git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@2126 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'test')
-rw-r--r--test/regression/annot1.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/regression/annot1.c b/test/regression/annot1.c
index 2763a8c..9bdf14e 100644
--- a/test/regression/annot1.c
+++ b/test/regression/annot1.c
@@ -49,6 +49,15 @@ int h(int a)
return dd;
}
+const int C1 = 42;
+const double C2 = 3.14;
+
+void k(int arg)
+{
+ __builtin_annot("C1 + 1 is %1 and arg is %2 and C2 * 2 is %3",
+ C1 + 1, arg, C2 * 2);
+}
+
int main()
{
__builtin_annot("calling f");