summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/imaginary-constants.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Reapply Sema: allow imaginary constants via GNU extension if UDL overloads ↵Tim Northover2017-08-091-0/+44
| | | | | | | | | | | | | | | | | | not present. C++14 added user-defined literal support for complex numbers so that you can write something like "complex<double> val = 2i". However, there is an existing GNU extension supporting this syntax and interpreting the result as a _Complex type. This changes parsing so that such literals are interpreted in terms of C++14's operators if an overload is present but otherwise falls back to the original GNU extension. (We now have more robust diagnostics for implicit conversions so the libc++ test that caused the original revert still passes). llvm-svn: 310478
* Revert "Sema: allow imaginary constants via GNU extension if UDL overloads ↵Tim Northover2017-05-241-44/+0
| | | | | | | | | not present." This reverts commit r303697. It broke libc++ tests that were specifically checking incompatibility in C++14 mode. llvm-svn: 303813
* Sema: allow imaginary constants via GNU extension if UDL overloads not present.Tim Northover2017-05-231-0/+44
C++14 added user-defined literal support for complex numbers so that you can write something like "complex<double> val = 2i". However, there is an existing GNU extension supporting this syntax and interpreting the result as a _Complex type. This changes parsing so that such literals are interpreted in terms of C++14's operators if an overload is present but otherwise falls back to the original GNU extension. llvm-svn: 303694
OpenPOWER on IntegriCloud