tmp/tmpi3dw14w8/{from.md → to.md}
RENAMED
|
@@ -37,13 +37,13 @@ local* p = 0; // error: local not found
|
|
| 37 |
An enclosing function has no special access to members of the local
|
| 38 |
class; it obeys the usual access rules [[class.access]]. Member
|
| 39 |
functions of a local class shall be defined within their class
|
| 40 |
definition, if they are defined at all.
|
| 41 |
|
| 42 |
-
|
| 43 |
-
class `X`
|
| 44 |
-
|
| 45 |
-
|
| 46 |
|
| 47 |
[*Note 2*: A local class cannot have static data members
|
| 48 |
[[class.static.data]]. — *end note*]
|
| 49 |
|
|
|
|
| 37 |
An enclosing function has no special access to members of the local
|
| 38 |
class; it obeys the usual access rules [[class.access]]. Member
|
| 39 |
functions of a local class shall be defined within their class
|
| 40 |
definition, if they are defined at all.
|
| 41 |
|
| 42 |
+
A class nested within a local class is a local class. A member of a
|
| 43 |
+
local class `X` shall be declared only in the definition of `X` or, if
|
| 44 |
+
the member is a nested class, in the nearest enclosing block scope of
|
| 45 |
+
`X`.
|
| 46 |
|
| 47 |
[*Note 2*: A local class cannot have static data members
|
| 48 |
[[class.static.data]]. — *end note*]
|
| 49 |
|