From: <kin...@us...> - 2011-08-16 04:02:31
|
Revision: 5065 http://teem.svn.sourceforge.net/teem/?rev=5065&view=rev Author: kindlmann Date: 2011-08-16 04:02:25 +0000 (Tue, 16 Aug 2011) Log Message: ----------- more on coding conventions Modified Paths: -------------- teem/trunk/src/CODING.txt Modified: teem/trunk/src/CODING.txt =================================================================== --- teem/trunk/src/CODING.txt 2011-08-16 03:51:47 UTC (rev 5064) +++ teem/trunk/src/CODING.txt 2011-08-16 04:02:25 UTC (rev 5065) @@ -145,10 +145,10 @@ unsigned int axis, int incrDim); * In public headers, ONLY use "..." to indicate var-args arguments. -That includes in comments; use ".." instead of "..." to refer to a -range of things, and ". . ." for regular ellipses. (why: to make it -trivial to see which functions are var-args; they can be the hardest -to debug). +"..." should be used in comments (in public headers). Use ".." +instead of "..." to refer to a range of things, and ". . ." for +regular ellipses in text. (why: to make it trivial to see which +functions are var-args; they can be the hardest to debug). * Any functions that are not intending to be public should be "static" in their source files, so that nothing accidentally links against them. @@ -184,7 +184,7 @@ for debugging purposes), rather than explicitly set by hand in the code (with a small fixed set of special exceptions, like airEndian) ** All enums end with a flag "last" value, with a name ending in "Last" or -"_last"; (why: simple way to test bounds on +"_last"; (why: simple way to test bounds on valid values) ** None of the Teem enums are typecast to something distinct- the values are still just of type "int". Thus, to collectively refer to the {fooBarUnknown, fooBarA, fooBarB, fooBarC ...} enum values, we use @@ -313,6 +313,12 @@ * If a pointer should be initialized to NULL, then set it to NULL; Don't assume that a pointer in a struct will be NULL following a calloc. +* New libraries should be added only when it is abundantly obvious +that no existing library can contain the intended functionality. By +convention adopted in 2002, all Teem library names must be a WORD, not +an acronym. The language of the word need not be English (e.g. tijk, +Dutch for ticking, the fabric of pillow and mattress covering) + * Parts of the GNU style (http://www.gnu.org/prep/standards.html) which have been more or less followed in Teem: - avoid arbitrary limits on (memory) sizes of things (this is very hard) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |