[C++-sig] Re: Pyste: support for user defined code.

Nicodemus nicodemus at globalite.com.br
Sun Aug 17 20:36:56 CEST 2003


Prabhu Ramachandran wrote:

>>>>>>"N" == nicodemus  <nicodemus at globalite.com.br> writes:
>>>>>>            
>>>>>>
>
>    N> Hmm, agreed, those "add" are redundant anyway, and I like
>    N> "code" better than "include". 8)
>
>    N> The names in caps indicates the sections in the source file
>    N> where the code should go:
>
>Rather than using the special all caps MODULE etc. why not just do
>this:
>
> add_header(...)
> add_declaration(...)
> add_module(...)
>
>or 
>
> code_header(...)
> ...
>
>or
>
> header_code()
> declaration_code()
> module_code()
>
>I'd prefer any of these to code(MODULE, <code>) etc. since it looks
>much cleaner.
>  
>

Agreed. There's not enough cases to justify the use of constants. I think:

header_code()
declaration_code()
global_declaration_code()
module_code()

read nice.







More information about the Cplusplus-sig mailing list