diff options
Diffstat (limited to 'clang/test/SemaCXX/complex-folding.cpp')
| -rw-r--r-- | clang/test/SemaCXX/complex-folding.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/complex-folding.cpp b/clang/test/SemaCXX/complex-folding.cpp index 6a77bfdb310..1c2f9c73eb3 100644 --- a/clang/test/SemaCXX/complex-folding.cpp +++ b/clang/test/SemaCXX/complex-folding.cpp @@ -3,6 +3,14 @@ // Test the constant folding of builtin complex numbers. static_assert((0.0 + 0.0j) == (0.0 + 0.0j)); +static_assert((0.0 + 0.0j) != (0.0 + 0.0j)); // expected-error {{static_assert}} + +static_assert((0.0 + 0.0j) == 0.0); +static_assert(0.0 == (0.0 + 0.0j)); +static_assert(0.0 == 0.0j); +static_assert((0.0 + 1.0j) != 0.0); +static_assert(1.0 != (0.0 + 0.0j)); +static_assert(0.0 != 1.0j); // Walk around the complex plane stepping between angular differences and // equality. |

