A simple rule

downs default_357-line at yahoo.de
Fri Jul 31 11:22:27 PDT 2009


Sergey Gromov wrote:
> Thu, 30 Jul 2009 21:57:33 +0200, downs wrote:
> 
>> 1) If it's a word, put it in the standard library.
>> 2) Otherwise, put it in the compiler.
>>
>> For example:
>>
>> assert() -> library.
>> complex -> library.
>> void -> C-derived, compiler.
>> real -> C-derived via long float, compiler.
>> cfloat -> library.
>> for -> compiler.
>> foreach -> library.
>> T[] -> compiler.
>> T.dup, T.sort, T.reverse -> library.
> 
> This is one weird rule.  This is probably because I'm not a native
> English speaker, but I fail to see why 'complex' and 'foreach' are words
> but 'for' is not.  You probably need to clarify what a 'word' is.
> 
> Should all key /words/ go into the library?

You left out the part where I specifically excluded C keywords, because it's good to have some base set to fall back on :)



More information about the Digitalmars-d mailing list