Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cornell!batcomputer!lacey From: lacey@batcomputer.tn.cornell.edu (John Lacey) Newsgroups: gnu.gcc Subject: Re: spotting syntax errors Message-ID: <8385@batcomputer.tn.cornell.edu> Date: 12 Jul 89 22:35:20 GMT References: Reply-To: lacey@tcgould.tn.cornell.edu (John Lacey) Distribution: gnu Organization: Cornell Theory Center, Cornell University, Ithaca NY Lines: 27 In article sr16+@ANDREW.CMU.EDU (Seth Benjamin Rothenberg) writes: >I recently tried to compile a program with an unclosed comment in it. > [ ... ] >Since nested comments generally do cause errors, they should >be disallowed. Thus, when the compiler spots a nested comment, >it could flag it, including a pointer to original (unclosed) comment. > [ ... ] >rejecting nested comments would make finding this error easier. Well, pointers generally do cause errors also (or at least as much as nested comments) and are even harder to debug. Therefore, to protect ourselves, pointers should be disallowed. No, no, no. If you want a fascist language, fine. Use one. Do not try to change every language to your fascist ideal. Nested comments are, like pointers, extremely useful. For one thing, they allow to comment out blocks of code without having to worry about comments inside the block. (Though I confess, I usually use a #ifdef OBSOLETE or some such to "delete" blocks in that fashion.) More importantly, why did you post this to gnu.gcc, and not comp.lang.c? Follow-ups there, if you all please. -- John Lacey | Internet: lacey@tcgould.tn.cornell.edu running unattached | BITnet: lacey@crnlthry | UUCP: cornell!batcomputer!lacey "Whereof one cannot speak, thereof one must remain silent." ---Wittgenstein