1 //===----------------------------------------------------------------------===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is dual licensed under the MIT and the University of Illinois Open
6 // Source Licenses. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 // <chrono>
11 
12 #include <complex>
13 #include <type_traits>
14 #include <cassert>
15 
main()16 int main()
17 {
18 #if _LIBCPP_STD_VER > 11
19     using namespace std;
20 
21     {
22     std::complex<long double> c1 = 3.0il;
23     assert ( c1 == std::complex<long double>(0, 3.0));
24     auto c2 = 3il;
25     assert ( c1 == c2 );
26     }
27 
28     {
29     std::complex<double> c1 = 3.0i;
30     assert ( c1 == std::complex<double>(0, 3.0));
31     auto c2 = 3i;
32     assert ( c1 == c2 );
33     }
34 
35     {
36     std::complex<float> c1 = 3.0if;
37     assert ( c1 == std::complex<float>(0, 3.0));
38     auto c2 = 3if;
39     assert ( c1 == c2 );
40     }
41 
42 #endif
43 }
44