Coding Style

(Added Portability)
(Coding)
Line 90: Line 90:
* Use std::min() / std::max() instead of a #define (windows needs NOMINMAX to be defined before including windows.h).
* Use std::min() / std::max() instead of a #define (windows needs NOMINMAX to be defined before including windows.h).
* avoid using 'friend' for classes
* avoid using 'friend' for classes
 +
* use postfix operators like i++, not ++i (unless there is a difference, e.g. if i should be a class, not a simple type). It was checked that there is no difference in the created code, and us developers prefer postfix.
== Portability ==
== Portability ==

Revision as of 12:22, 26 November 2014

Retrieved from "http://supertuxkart.sourceforge.net/Coding_Style"

User Tools