Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
calint committed Jan 12, 2025
1 parent 2cff6a3 commit d0473f2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion os/src/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
- functions are requested to be inlined assuming compilers won't adhere to the hint when it does not make sense, such as big functions called from multiple locations
- functions called from only one location should be inlined
* `const` is preferred and used where applicable
* `let` and `mut` are defined as `auto const` and `auto` and used to declare variables or constants
* `auto` is used when the type name is too verbose, such as iterators and templates; otherwise, types are spelled out for readability
* `let` and `mut` are defined as `auto const` and `auto` and can be used to declare variables and immutables
* `using namespace std;` is ok within namespace or implementation
* right to left notation `some_type const &inst` instead of `const some_type &inst`
- for consistency, `const` is written after the type such as `char const *ptr` instead of `const char *ptr` and `float const x` instead of `const float x`
Expand Down

0 comments on commit d0473f2

Please sign in to comment.