diff options
| author | Wladimir J. van der Laan <[email protected]> | 2017-05-11 07:17:10 +0200 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2017-05-11 07:18:18 +0200 |
| commit | 7f2b9e0868f5759187e63df4f2cbd5f4fc9c81d7 (patch) | |
| tree | f7bd88dc933df932680562475ce57fc5a5cab781 | |
| parent | Merge #10325: 0.15.0 Depends Updates (diff) | |
| parent | Shadowing is not enabled by default, update doc accordingly. (diff) | |
| download | discoin-7f2b9e0868f5759187e63df4f2cbd5f4fc9c81d7.tar.xz discoin-7f2b9e0868f5759187e63df4f2cbd5f4fc9c81d7.zip | |
Merge #10381: Shadowing warnings are not enabled by default, update doc accordingly
f203ecc Shadowing is not enabled by default, update doc accordingly. (Pavel JanÃk)
Tree-SHA512: a7170827caa9d35457356808445ef2387fd2edde72fb76c6241cfd5decad218558b307d223e86bb66041576b638f90f6efa8a46ea6208d43da275a993617c997
| -rw-r--r-- | doc/developer-notes.md | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/doc/developer-notes.md b/doc/developer-notes.md index fd75ada79..cf860a1bf 100644 --- a/doc/developer-notes.md +++ b/doc/developer-notes.md @@ -343,10 +343,9 @@ Strings and formatting Variable names -------------- -The shadowing warning (`-Wshadow`) is enabled by default. It prevents issues rising -from using a different variable with the same name. - -Please name variables so that their names do not shadow variables defined in the source code. +Although the shadowing warning (`-Wshadow`) is not enabled by default (it prevents issues rising +from using a different variable with the same name), +please name variables so that their names do not shadow variables defined in the source code. E.g. in member initializers, prepend `_` to the argument name shadowing the member name: |