nested comments
Ary Manzana
ary at esperanto.org.ar
Mon May 30 18:52:05 PDT 2011
On 5/31/11 7:58 AM, Nick Sabalausky wrote:
> "bearophile"<bearophileHUGS at lycos.com> wrote in message
> news:is1dj6$ihb$1 at digitalmars.com...
>> Jesse Phillips:
>>
>>> The purpose is commenting out code, but note that there is also
>>> version(none) { } which is never compiled in.
>>
>> version(none) {} is probably the official way to comment out code.
>> And if you use a versioning system to keep your code, then commenting out
>> code is not a so wise thing to do.
>>
>
> Why not? I've never heard of a VCS that went around stripping out all
> comments.
The question is: why comment and commit code that you can already find
in the commit history? Then you end up with huge files with things like:
/*
* Maybe we will use this in a future, this is not working right now
...
...
...
*/
and the code becomes a mess.
So I agree with bearophile here.
More information about the Digitalmars-d-learn
mailing list