diff --git a/doc/sgpem2dman.texi b/doc/sgpem2dman.texi index 275d336..d05507c 100644 --- a/doc/sgpem2dman.texi +++ b/doc/sgpem2dman.texi @@ -90,6 +90,11 @@ Free Documentation License''. @table @strong +@item 2006, January 24th, @r{--- Luca Vezzaro} +Updated some code snippets whose style were +inconsistent with our coding rules. Added the point on +operator overloading to the coding conventions. + @item 2005, December 26th, @r{--- Matteo Settenvini} Changed directory layout for @samp{src}. Added @samp{swe/prototypes} to repository layout. @@ -309,7 +314,8 @@ Labels go indented on the same level of the containing code block. For example: @example @verbatim -switch(x) { +switch(x) +{ case 1: // foo case 2: @@ -332,7 +338,8 @@ documenting it. For example: class C; // [...] -class C { +class C +{ public: // [...] }; @@ -546,12 +553,14 @@ containing class. For example: @verbatim class C; -class C { +class C +{ class D; // ... }; -class C::D { +class C::D +{ // ... }; @end verbatim @@ -559,6 +568,19 @@ class C::D { The order for visibility should be: @code{public}, then @code{protected}, then @code{private}. +@item +Use operator overloading with care, only define +overloaded operators if the use of that operator is a +natural way to perform a particular operation on the +object(s). +In case operator overloading is considered the +best choice, a lot of operators should still be avoided +due to their profound integration with the language, +and their tendency to lead to ugly bugs. Some +examples of these operators are: the casting operator, +@code{operator delete}, @code{operator new}, +@code{operator ^}. + @end enumerate