From 48d09fcab8a1234cd27909124d2538645443216c Mon Sep 17 00:00:00 2001 From: chaoskagami Date: Mon, 23 May 2016 20:30:03 -0400 Subject: [PATCH] Coding standard info --- doc/coding-standard.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 doc/coding-standard.md diff --git a/doc/coding-standard.md b/doc/coding-standard.md new file mode 100644 index 0000000..6e95411 --- /dev/null +++ b/doc/coding-standard.md @@ -0,0 +1,16 @@ +There's only *one* real hard rule: run `make reformat` before you commit. + +Format is a modified mozilla standard - four spaces, not two. + +Also, there's a few hard-enforced rules you need to obey if you want to submit code: + + 1) Avoid trigraphs at all costs. Only use them if it actually helps readability. + + 2) Any `#pragma` macros are banned. You're using linux and GCC, so stop using MSVCisms. + There's another few quirks about #pragma once that mean I have to use guards instead. + Use `__atrribute__` instead. + + 3) If by some odd chance you use inline assembly; use `__asm__`, not `asm`. + + 4) Do not remove `-Werror`. It's there for a reason. Your code should be squeaky clean; + if not, find a way to make your code correct. This is mandatory. -- 2.39.5