Updated NEP 1 : Style Guide for Nimrod Code (markdown)

This commit is contained in:
Varriount 2014-07-29 13:44:50 -07:00
parent 57cc6fcb5e
commit a902e6d854
1 changed files with 7 additions and 5 deletions

View File

@ -26,11 +26,12 @@ Style Guidelines
code is more consistant across editors. Unlike spaces, tabstop width varies
across editors, and not all editors provide means of changing this width.
- Use of extra whitespace for alignment in ways other than dictated by the
style guide is discouraged. Manual alignment and re-alignment of code is
tedious, and not all editors have support for auto-alignment of code
sections, plus re-alignment of code blocks causes larger, less distinct
code diffs.
- Although use of whitespace for stylistic reasons other than the ones endorsed
by this guide are allowed, careful thought should be put into such practices.
Not all editors support automatic alignment of code sections, and re-aligning
long sections of code by hand can quickly become tedius. Furthermore, the large
changes that re-alignment causes can make it harder to view actual,
program-altering changes when diffs are viewed.
```nimrod
# This is bad, as the next time someone comes
# to edit this code block, they
@ -38,6 +39,7 @@ Style Guidelines
type
WordBool* = int16
CalType* = int
... # 5 lines later
CalId* = int
LongLong* = int64
LongLongPtr* = ptr LongLong