Clarify usage of pointers and references in code (#1778)

This commit is contained in:
UdjinM6 2017-12-14 03:33:08 +03:00 committed by GitHub
parent f37a64208c
commit 0291604ad0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -12,6 +12,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.
- Align pointers and references to the left i.e. use `type& var` and not `type &var`.
Block style example:
```c++
@ -19,7 +20,7 @@ namespace foo
{
class Class
{
bool Function(char* psz, int n)
bool Function(char* psz, int n, const string& s)
{
// Comment summarising what this section of code does
for (int i = 0; i < n; i++) {