First a confession: I would not mind seeing such a feature. It would be nice if it were portable to other Smalltalks, but it would be useful. That said, (I can't *believe* I'm writing this... <g>) XP advocates would tell us that we don't need the code and to just delete it. With readily obtainable version history, there is a way to recover from such an action. The rebuttal is that versions can get lost overt time, out-of-sight/out-of-mind, etc.. More times than I care to count, clear dated comments, and commented code, have saved me LOTS of trouble. I think the record is that in about an hour, I fixed a defect that had been lurking for several years. Had I removed old code that wasn't quite right, I'd have been in a real spot. But seeing the failure that arose and things that didn't quite work in the past, I was able to create a working solution. Comments are good. Bill ________________________________________ From: pharo-project-bounces@lists.gforge.inria.fr [pharo-project-bounces@lists.gforge.inria.fr] on behalf of Lukas Renggli [renggli@gmail.com] Sent: Monday, October 31, 2011 5:22 PM To: Pharo-project@lists.gforge.inria.fr Subject: Re: [Pharo-project] Comment Syntax The problem is that both #/* and #/* are valid binary operators, so they don't work well for comments. I don't really remember what I proposed a few years ago, although I remember that exactly the same proposal was made. What would work is to use something like "* and *" (or any other double thing that starts with a double quote). Like this the comments could contain double quotes. As a short term solution you can also put your comments into single quotes. Unused string literals are removed by the compiler. Lukas On 31 October 2011 22:00, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
Me too.
Sean lukas proposed a syntax for that in the mailing-list a year ago. If you find it please resent it.
Stef
On Oct 31, 2011, at 9:12 PM, Sean P. DeNigris wrote:
Would it be difficult/valuable to create an alternate comment syntax? I often find myself wanting to comment a large block itself containing comments. It would be nice to have something like C++'s /* */. I feel like this may have been brought up before, but couldn't find it searching the lists.
Sean
-- View this message in context: http://forum.world.st/Comment-Syntax-tp3961451p3961451.html Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
-- Lukas Renggli www.lukas-renggli.ch