From 68be1649ee65d59468e01f69862b7709134ed423 Mon Sep 17 00:00:00 2001 From: Eli Friedman Date: Thu, 4 Oct 2012 02:36:51 +0000 Subject: Permanently end the whole "pragma got handled by the parser too early" mess by handling all pragmas which the parser touches uniformly. , etc. llvm-svn: 165195 --- clang/test/CodeGen/fp-contract-pragma.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'clang/test/CodeGen/fp-contract-pragma.cpp') diff --git a/clang/test/CodeGen/fp-contract-pragma.cpp b/clang/test/CodeGen/fp-contract-pragma.cpp index 723ac1f4637..9be9afc4c29 100644 --- a/clang/test/CodeGen/fp-contract-pragma.cpp +++ b/clang/test/CodeGen/fp-contract-pragma.cpp @@ -34,3 +34,15 @@ float fp_contract_3(float a, float b, float c) { // CHECK: tail call float @llvm.fmuladd return template_muladd(a, b, c); } + +template class fp_contract_4 { + float method(float a, float b, float c) { + #pragma STDC FP_CONTRACT ON + return a * b + c; + #pragma STDC FP_CONTRACT OFF + } +}; + +template class fp_contract_4; +// CHECK: _ZN13fp_contract_4IiE6methodEfff +// CHECK: tail call float @llvm.fmuladd -- cgit v1.2.3