* gcc.dg/unordered-1.c: New test.

From-SVN: r50402
This commit is contained in:
Richard Sandiford 2002-03-07 11:39:13 +00:00 committed by Richard Sandiford
parent 71925bc04f
commit e106e1b07e
2 changed files with 22 additions and 0 deletions

View File

@ -1,3 +1,7 @@
2002-03-07 Richard Sandiford <rsandifo@redhat.com>
* gcc.dg/unordered-1.c: New test.
2002-03-07 Richard Earnshaw <rearnsha@arm.com>
* gcc.c-torture/execute/20020307-1.c: New test.

View File

@ -0,0 +1,18 @@
/* { dg-do compile } */
void bar (int);
void foo (int i, float f)
{
bar (__builtin_isgreater (i, i)); /* { dg-error "non-floating-point" } */
bar (__builtin_isgreater (f, i));
bar (__builtin_isgreater (i, f));
bar (__builtin_isgreater (f, 2));
bar (__builtin_isgreater (f, 2.0f));
bar (__builtin_isgreater (f, 2.0));
bar (__builtin_isgreater (2, f));
bar (__builtin_isgreater (2.0f, f));
bar (__builtin_isgreater (2.0, f));
bar (__builtin_isgreater (&f, i)); /* { dg-error "non-floating-point" } */
bar (__builtin_isgreater (f, &i)); /* { dg-error "non-floating-point" } */
}