You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
527 B
12 lines
527 B
// RUN: %clang_cc1 -fexperimental-strict-floating-point -fsyntax-only -Wignored-pragmas -verify %s
|
|
|
|
#pragma STDC FENV_ROUND ON // expected-warning {{invalid or unsupported rounding mode}}
|
|
|
|
float func_01(int x, float y) {
|
|
if (x)
|
|
return y + 2;
|
|
#pragma STDC FENV_ROUND FE_DOWNWARD // expected-error{{'#pragma STDC FENV_ROUND' can only appear at file scope or at the start of a compound statement}}
|
|
// expected-warning@-1{{pragma STDC FENV_ROUND is not supported}}
|
|
return x + y;
|
|
}
|