Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site decwrl.UUCP Path: utzoo!linus!decvax!decwrl!dec-rhea!dec-mrvax!ddb From: ddb@mrvax.DEC (DAVID DYER-BENNET MRO1-2/L14 DTN 231-4076) Newsgroups: net.lang.c Subject: Commenting out code Message-ID: <3940@decwrl.UUCP> Date: Wed, 17-Oct-84 11:06:35 EDT Article-I.D.: decwrl.3940 Posted: Wed Oct 17 11:06:35 1984 Date-Received: Thu, 18-Oct-84 08:07:06 EDT Sender: daemon@decwrl.UUCP Organization: DEC Engineering Network Lines: 23 Using conditional compilation to "comment out" code works very reliably, but that's about the only thing I like about it. 1. It takes two additional lines to comment out one line of code. 2. When commenting out a large chunk, it isn't easy to tell in the middle that this code isn't really there. Thus, it has problems in both the small and the large cases. The ideal way to comment out code is by using a comment syntax where a comment continues exactly and precisely to the end of the line; you then put this at the beginning of each line to remove. This form of comment is uniformly better than these stupid /* */ things we're stuck with in C now. For example, assuming a 2-character "start comment" sequence, it saves you two characters in comments placed at the end of a line (and at deep indentation levels this can be important). -- David Dyer-Bennet -- ...decwrl!dec-rhea!dec-mrvax!ddb So consider this a suggestion.