I've explained on the text. The minus "-" is the key right over the brackets on USA based keyboards, and at a good right spot in almost all accessible in just one key press. The square brackets, are not available (visually) in some and you need to find a combination of keys to invoke it. Instead of 3 physical keys involved, we will have just 2. "/" and "-", instead of "#", "[", and "]". The complex keystrokes #[ and ]# becomes just the positional elements //- -//
As you can see, it was planned to even create good visual "header like" comment as a side effect.
//-------------------- Header ---------------------- This is good. ----------------------------------------------------//
I don't think your comment syntax should be aded. Nim has a Pythonesque style it should just keep it. Its not what you add, its what you don't add makes a great language.
I also don't agree with / / it should just be a C like system with / / and / * ... * / and / * * ... * / not some thing unfamiliar.
I also feel that syntax is not that important, its the C inter-op, type system and the operator overloading, and speed which makes me excited about nim. The language would have been fine with C like if(){} / * ... * / syntax but it choose the python's if : # syntax and that just small layer to the language.
Your proposal doesn't work well with the current Nim, // can be an operator:
# let's be even more like Python
proc `//`(a, b: int): int = a div b
echo 3 // 4
And your argument comes down to "I cannot be bothered to use a custom keyboard shortcut to type '#'". ;-)
Once you reserve "//", "//-"and "-//" this will stop to occur.
Can we do this?
#// Let's be more than Python proc `#`(a, b: int): int = a div b echo 3 # 4 #// I believe that the above code fails as I hope
Nim is full of alternative ways of doing the same things, and this is beautiful.
Preference and style. This will aggregate more people.
I like the language, but I hate the "#" so much (as others) that I decided to waste some time here to expose this fact, and try to convince pythonic purists that there is a huge team of "//" lovers out there, and this would be a great benefit to the language.
Nim would not be alone in such regard of having alternative ways of commenting, Xojo for instance, started using " ' " and later added the usual " // ".
I can't see myself writing:
' This is a comment
Instead of
// This is a comment
But the language accepts both, and few people use the old way, nobody cares.
(https://s28.postimg.org/5ugjzoeql/tiobe-double-slashes.png)
As for Ad Hominems, it's made when someone attacks another person, and not his/her arguments. No attacks against anyone were made while argumenting. No Ad Hominems were made, by me, at least.
I have no problems. I want to help. Accept or deny. My life will move on.
No attacks against anyone
You called people
pythonic purists
which is obviously referring to people rather than the issue itself.
I have no problems.
Your previous posts sounded differently.
I want to help. Accept or deny.
Lacking commitment to discuss does not make your proposal look better.
In my keyboard both '#' and '/' takes two keystrokes.
For the record, my keyboard has a one-key #, but / takes two keys. However, I don't use the standard keyboard layout anyway.
Pythonic purist is a class of people, some probably proud of being it, it's not an offense, unless someone dislikes python and has been called of it. No one here was called of pythonic purist, the argument just presumed the possibility of being read by one, here. And such one probably would attack the argument because its nature.
One key # is found only in UK and Ireland a far as I know. Lucky guys, they are.
Any keyboard, any standard, with numeric keypad, has + - * and /.
The proposal does not remove such use, just expands the possibilities, so the pro "#" can keep using it side by side with the pro "//" people.
All arguments were done. Requested proof of importance presented. No need to extend pro argumentation anymore. Just need people to think more open minded and understand that "this feature" adds much more than takes. To be true, it just adds.
One key # is found only in UK and Ireland a far as I know.
Germany…
Any keyboard, any standard, with numeric keypad, has + - * and /.
So moving your hand over to the numpad and back is faster than pressing two keys?
Just need people to think more open minded and understand that "this feature" adds much more than takes.
Ad hominem again. You assume that people who oppose your proposition are not „open minded“ (enough).
To be true, it just adds.
So far, none of your arguments convinced me even a bit that this adds anything beyond complexity.
Just need people to think more open minded and understand that "this feature" adds much more than takes. To be true, it just adds.
As already stated, this is wrong. It takes away the // operator (that you don't care about), and it introduces more divergent styles of writing code. And for choosing between # and // in the first place, # has an advantage over // that I already mentioned. You can look that up. And since you said you take keyboard layouts in consideration, here is my keyboard layout:
So please reweight your decisions.