Updated Coding Standards (markdown)
parent
0626ec50eb
commit
613f1c5a9a
1 changed files with 4 additions and 4 deletions
|
|
@ -1,11 +1,11 @@
|
|||
Please follow these coding standards for contributing code to Marlin. Pull requests which fail to follow good coding standards may be postponed for cleanup.
|
||||
|
||||
- Coding Style
|
||||
- [Coding Style](#coding-style)
|
||||
- [Indentation](#indentation) - Elements that require indentation
|
||||
- [Bracket Style](#bracket-style) - The one true bracket style
|
||||
- [Spacing](#spacing) - No tabs allowed, 2 space indentation, etc.
|
||||
- [Comments](#comments) - Multi-line, single-line…
|
||||
- Names and Symbols
|
||||
- [Names and Symbols](#names-and-symbols)
|
||||
- [Capitalization](#capitalization)
|
||||
- [Filenames](#filenames)
|
||||
- [Directories](#directories)
|
||||
|
|
@ -19,6 +19,7 @@ Please follow these coding standards for contributing code to Marlin. Pull reque
|
|||
- [Preprocessor Directives](#preprocessor-directives) – Faster compilation, smaller code
|
||||
- [Adding a New Features](#adding-a-new-feature) – Make Marlin better with your own code
|
||||
|
||||
## Coding Style
|
||||
### Indentation
|
||||
Indentation is important for readability and maintainability of code, and provides guidance for naïve code editors (e.g., TextMate, Sublime, et. al.) to properly fold code blocks by level.
|
||||
|
||||
|
|
@ -66,6 +67,7 @@ else {
|
|||
- Doxygen-style headings (documenting in .h files), C++ single-line style // for under 3 lines
|
||||
- Multi-line use asterisks in the second column
|
||||
|
||||
## Names and Symbols
|
||||
### Capitalization
|
||||
|
||||
- ClassMethod
|
||||
|
|
@ -113,8 +115,6 @@ Marlin is written in C/C++ and must be able to compile with the supplied Makefil
|
|||
- `millis()` can be expensive so put it in a `uint32_t` if you need it more than once.
|
||||
- Pre-calculate if possible instead of calculating on the fly
|
||||
|
||||
---
|
||||
|
||||
## Marlin-specific Conventions
|
||||
|
||||
### Preprocessor directives
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue