From 87c81ba6f9cdbf4a4fc025d4bf1c74ba852a1fd4 Mon Sep 17 00:00:00 2001 From: "Wladimir J. van der Laan" Date: Fri, 26 Aug 2016 15:54:25 +0200 Subject: [PATCH] Merge #8602: [trivial][doc] Mention ++i as preferred over i++ in dev notes ab53207 [trivial][doc] Mention ++i as preferred to i++ in dev notes (fanquake) --- doc/developer-notes.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/doc/developer-notes.md b/doc/developer-notes.md index f27264d35..79f552ec9 100644 --- a/doc/developer-notes.md +++ b/doc/developer-notes.md @@ -14,6 +14,7 @@ gradually. - No indentation for public/protected/private or for namespaces. - No extra spaces inside parenthesis; don't do ( this ) - No space after function names; one space after if, for and while. + - `++i` is preferred over `i++`. - Align pointers and references to the left i.e. use `type& var` and not `type &var`. Block style example: @@ -25,7 +26,7 @@ class Class bool Function(char* psz, int n, const string& s) { // Comment summarising what this section of code does - for (int i = 0; i < n; i++) { + for (int i = 0; i < n; ++i) { // When something fails, return early if (!Something()) return false; @@ -234,9 +235,9 @@ General Dash Core - *Rationale*: Makes sure that they pass thorough testing, and that the tester will keep passing on the master branch. Otherwise all new pull requests will start failing the tests, resulting in confusion and mayhem - + - *Explanation*: If the test suite is to be updated for a change, this has to - be done first + be done first Wallet -------