aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2017-08-18 15:23:54 +0200
committerWladimir J. van der Laan <laanwj@gmail.com>2017-08-18 15:24:07 +0200
commit9e00a625b43c86a1a25c7d8a6d0b06bd4db5904a (patch)
treef4a6926069e5135154f150217d042a4739e61a38 /doc
parentaeec8b4b688235bb61827c2543875729c3686091 (diff)
parentbea8e9e66ea98a957b8318cd49d91b598f38cbd3 (diff)
Merge #11066: Document the preference of nullptr over NULL or (void*)0
bea8e9e Document the preference of nullptr over NULL or (void*)0 (practicalswift) Pull request description: Document the preference of `nullptr` over `NULL` or `(void*)0`. After this commit: ``` $ git grep "[^A-Za-z_]NULL[^A-Za-z_]" | grep -vE '(leveldb|univalue|secp256k1|torcontrol|NULL certificates|ctaes|release-notes|patches|configure.ac|developer-notes)' $ ``` Some context: * `NULL → nullptr` was handled in the recently merged PR #10483 * `0 → nullptr` was handled in the recently merged PR #10645 Tree-SHA512: f863096aa4eb21705910f89713ca9cc0d83c6df2147e3d3530c3e1589b96f6c68de8755dcf37d8ce99ebda3cfb69805e00eab13bf65424aaf16170e9dda3958a
Diffstat (limited to 'doc')
-rw-r--r--doc/developer-notes.md3
1 files changed, 2 insertions, 1 deletions
diff --git a/doc/developer-notes.md b/doc/developer-notes.md
index 77260bbdfd..9b85600ccc 100644
--- a/doc/developer-notes.md
+++ b/doc/developer-notes.md
@@ -37,6 +37,7 @@ code.
- **Miscellaneous**
- `++i` is preferred over `i++`.
+ - `nullptr` is preferred over `NULL` or `(void*)0`.
- `static_assert` is preferred over `assert` where possible. Generally; compile-time checking is preferred over run-time checking.
Block style example:
@@ -276,7 +277,7 @@ Wallet
- *Rationale*: In RPC code that conditionally uses the wallet (such as
`validateaddress`) it is easy to forget that global pointer `pwalletMain`
- can be NULL. See `test/functional/disablewallet.py` for functional tests
+ can be nullptr. See `test/functional/disablewallet.py` for functional tests
exercising the API with `-disablewallet`
- Include `db_cxx.h` (BerkeleyDB header) only when `ENABLE_WALLET` is set