From Jason Turner

[depr.static.constexpr]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmp4anee8nn/{from.md → to.md} +18 -0
tmp/tmp4anee8nn/{from.md → to.md} RENAMED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ## Redeclaration of `static constexpr` data members <a id="depr.static.constexpr">[[depr.static.constexpr]]</a>
2
+
3
+ For compatibility with prior C++ International Standards, a `constexpr`
4
+ static data member may be redundantly redeclared outside the class with
5
+ no initializer. This usage is deprecated.
6
+
7
+ [*Example 1*:
8
+
9
+ ``` cpp
10
+ struct A {
11
+ static constexpr int n = 5; // definition (declaration in C++14{})
12
+ };
13
+
14
+ constexpr int A::n; // redundant declaration (definition in C++14{})
15
+ ```
16
+
17
+ — *end example*]
18
+