Block Comments Are a Bad Idea
futhark-lang.org
Block Comments Are a Bad Idea
1–10 of 84 posts
Re: Block Comments Are a Bad Idea
#2I don't know if Python's triple-quote can be used inline, but otherwise that seems like a good solution. I am not entirely familiar with Python comments, does any of his arguments apply to triple-quotes?
Re: Block Comments Are a Bad Idea
#3Re: Block Comments Are a Bad Idea
#4How would one do inline comments without block comments? I don't know if Python's triple-quote can be used inline, but otherwise that seems like a good solution. I am not entirely familiar with Python comments, does any of his arguments apply to triple-quotes?
Re: Block Comments Are a Bad Idea
#5Re: Block Comments Are a Bad Idea
#6Commenting out whole sections of code incredibly useful for debugging and rapid prototyping.
Re: Block Comments Are a Bad Idea
#7For blocks comments in a functional language though, it might work because many people would come from LISP/Scheme, where block comments were never a thing (I think.)
Re: Block Comments Are a Bad Idea
#8This is my personal preference, but from experience I prefer languages that don't shun concepts because they're bad programming practice. I can understand if something is difficult to implement or prevents other features from being added, but if a feature is possible, I say add it---it might come in handy sometimes. There's a reason languages like C, C++, Ruby, and Javascript are immensely popular. It's because progr…
Re: Block Comments Are a Bad Idea
#9The D Programming Language - Conditional Compilation: https://dlang.org/spec/version.html
Re: Block Comments Are a Bad Idea
#10I, am not too unhappy with the behaviour of C/C++/Java/... - That the block comment will end at the first occurence of " * / ".
If I accidentally close a comment too early (because there already was another block comment inside the code I want to comment), then...
* The syntax highlighting of my IDE will tell me.
* The compiler will tell me.
* I can take it as an opportunity to consider whether this file is too large - That problem should not have happened at all.