Skip to content

Commit

Permalink
Add support for Name Shadowing
Browse files Browse the repository at this point in the history
  • Loading branch information
RexJaeschke authored and BillWagner committed Feb 6, 2023
1 parent a01177c commit 2526b97
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion standard/classes.md
Original file line number Diff line number Diff line change
Expand Up @@ -2062,7 +2062,7 @@ A *parameter_array* may occur after an optional parameter, but cannot have a def
>
> *end example*
A method declaration creates a separate declaration space ([§7.3](basic-concepts.md#73-declarations)) for parameters and type parameters. Names are introduced into this declaration space by the type parameter list and the formal parameter list of the method. The body of the method, if any, is considered to be nested within this declaration space. It is an error for two members of a method declaration space to have the same name. It is an error for the method declaration space and the local variable declaration space of a nested declaration space to contain elements with the same name.
A method declaration creates a separate declaration space ([§7.3](basic-concepts.md#73-declarations)) for parameters and type parameters. Names are introduced into this declaration space by the type parameter list and the formal parameter list of the method. The body of the method, if any, is considered to be nested within this declaration space. It is an error for two members of a method declaration space to have the same name.
A method invocation ([§11.7.8.2](expressions.md#11782-method-invocations)) creates a copy, specific to that invocation, of the formal parameters and local variables of the method, and the argument list of the invocation assigns values or variable references to the newly created formal parameters. Within the *block* of a method, formal parameters can be referenced by their identifiers in *simple_name* expressions ([§11.7.4](expressions.md#1174-simple-names)).
Expand Down

0 comments on commit 2526b97

Please sign in to comment.