Support and General Use > Theming and Appearance Customization

two minor comment handling changes

<< < (2/4) > >>

BdN3504:
i wouldn't commit the weather. but i'd go with %. good idea to introduce this behaviour (both parts).

Llorean:
I'd say the symbol needs to be something that appears in common keyboard layouts. Personally I'm fond of "\" as it's used in a lot of other cases. % also works, but as it's the standard escape character I have a few doubts about it. I really don't like using # as a line end (though I guess technically, that's how it works now).

I'm not entirely sure the first part even needs to be fixed (honestly, I'm surprised we allow mid-line comments, but it seems to me the current method of doing it, even if it will catch people by surprise the first time it happens, is actually slightly more flexible overall once you know it exists).

gevaerts:

--- Quote from: Llorean on September 09, 2009, 02:23:10 PM ---% also works, but as it's the standard escape character I have a few doubts about it.

--- End quote ---

It being the standard escape character is what makes this the logical choice. Any other character would need some way of specifying that it shouldn't trigger a continuation line.

JdGordon:
% is the current escape char is the best reason to use it....

I think there is a flaw in the #comment at the end of the line eating the \n though... I think it shouldnt eat it if the line still ends in % (or whatever char we decide on) so you can still break up long lines, and comment on the same line instead of above or below the code

What are your doubts about %?

I get the impression that alot of people dont put comments in their wps which makes debugging and understanding very hard... I'm trying to make it easier (and so hopefully get more people to add them)

Angus_NB:
Some programming languages, Visual Basic, VBA, use the _ character.
My opinion, % is used so much within the WPS code that it would be confusing to also use it within comments.

Over 100 views but only 10 of us voted.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version