From Jason Turner

[complex.syn]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpuso11763/{from.md → to.md} +20 -8
tmp/tmpuso11763/{from.md → to.md} RENAMED
@@ -29,30 +29,30 @@ namespace std {
29
  template<class T> complex<T> operator/(const T&, const complex<T>&);
30
 
31
  template<class T> complex<T> operator+(const complex<T>&);
32
  template<class T> complex<T> operator-(const complex<T>&);
33
 
34
- template<class T> bool operator==(
35
  const complex<T>&, const complex<T>&);
36
- template<class T> bool operator==(const complex<T>&, const T&);
37
- template<class T> bool operator==(const T&, const complex<T>&);
38
 
39
- template<class T> bool operator!=(const complex<T>&, const complex<T>&);
40
- template<class T> bool operator!=(const complex<T>&, const T&);
41
- template<class T> bool operator!=(const T&, const complex<T>&);
42
 
43
  template<class T, class charT, class traits>
44
  basic_istream<charT, traits>&
45
  operator>>(basic_istream<charT, traits>&, complex<T>&);
46
 
47
  template<class T, class charT, class traits>
48
  basic_ostream<charT, traits>&
49
  operator<<(basic_ostream<charT, traits>&, const complex<T>&);
50
 
51
  // [complex.value.ops], values:
52
- template<class T> T real(const complex<T>&);
53
- template<class T> T imag(const complex<T>&);
54
 
55
  template<class T> T abs(const complex<T>&);
56
  template<class T> T arg(const complex<T>&);
57
  template<class T> T norm(const complex<T>&);
58
 
@@ -82,8 +82,20 @@ namespace std {
82
  template<class T> complex<T> sin (const complex<T>&);
83
  template<class T> complex<T> sinh (const complex<T>&);
84
  template<class T> complex<T> sqrt (const complex<T>&);
85
  template<class T> complex<T> tan (const complex<T>&);
86
  template<class T> complex<T> tanh (const complex<T>&);
 
 
 
 
 
 
 
 
 
 
 
 
87
  }
88
  ```
89
 
 
29
  template<class T> complex<T> operator/(const T&, const complex<T>&);
30
 
31
  template<class T> complex<T> operator+(const complex<T>&);
32
  template<class T> complex<T> operator-(const complex<T>&);
33
 
34
+ template<class T> constexpr bool operator==(
35
  const complex<T>&, const complex<T>&);
36
+ template<class T> constexpr bool operator==(const complex<T>&, const T&);
37
+ template<class T> constexpr bool operator==(const T&, const complex<T>&);
38
 
39
+ template<class T> constexpr bool operator!=(const complex<T>&, const complex<T>&);
40
+ template<class T> constexpr bool operator!=(const complex<T>&, const T&);
41
+ template<class T> constexpr bool operator!=(const T&, const complex<T>&);
42
 
43
  template<class T, class charT, class traits>
44
  basic_istream<charT, traits>&
45
  operator>>(basic_istream<charT, traits>&, complex<T>&);
46
 
47
  template<class T, class charT, class traits>
48
  basic_ostream<charT, traits>&
49
  operator<<(basic_ostream<charT, traits>&, const complex<T>&);
50
 
51
  // [complex.value.ops], values:
52
+ template<class T> constexpr T real(const complex<T>&);
53
+ template<class T> constexpr T imag(const complex<T>&);
54
 
55
  template<class T> T abs(const complex<T>&);
56
  template<class T> T arg(const complex<T>&);
57
  template<class T> T norm(const complex<T>&);
58
 
 
82
  template<class T> complex<T> sin (const complex<T>&);
83
  template<class T> complex<T> sinh (const complex<T>&);
84
  template<class T> complex<T> sqrt (const complex<T>&);
85
  template<class T> complex<T> tan (const complex<T>&);
86
  template<class T> complex<T> tanh (const complex<T>&);
87
+
88
+ // [complex.literals], complex literals:
89
+ inline namespace literals {
90
+ inline namespace complex_literals {
91
+ constexpr complex<long double> operator""il(long double);
92
+ constexpr complex<long double> operator""il(unsigned long long);
93
+ constexpr complex<double> operator""i(long double);
94
+ constexpr complex<double> operator""i(unsigned long long);
95
+ constexpr complex<float> operator""if(long double);
96
+ constexpr complex<float> operator""if(unsigned long long);
97
+ }
98
+ }
99
  }
100
  ```
101