mIRC Home    About    Download    Register    News    Help

Print Thread
Page 2 of 2 1 2
Joined: Jul 2006
Posts: 4,146
W
Hoopy frood
Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 4,146
I said a quirk is a bug that won't be fixed, otherwise you would call it a bug and it would get fixed

And I disagree strongly, at best what you are describing is a lack of thinking before implementation, if K didn't want ugly abuse with the timer command, he would have forced the call of an alias only, he didn't, he wants to keep compatibilities and he defends those who might be relying on either bugs or quirks, even the most illogical ones.
And let's be clear, the "Use the correct syntax and you'll be good" is a stupid argument, if each time I make a typo in my code, mIRC crashes, I'm going to complain, that's normal. If mIRC does not crash with my typo but I figure out it can do some undocumented stuff and people like it, they will use it, that's normal.

Last edited by Wims; 11/10/14 04:36 PM.

#mircscripting @ irc.swiftirc.net == the best mIRC help channel
Joined: Dec 2002
Posts: 5,412
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,412
In general, you should provide the parser with as much information as possible so that it does not have to guess what you mean. In this case, using the = sign with /var makes it clear to the parser, and to you when you later read the script, exactly where the assignment is taking place. The more information the parser has, the more likely the script will work in the way you expect. This applies to the = sign, brackets, and anything else that makes it clear to the parser what you mean.

As the parser supports $+ and [] brackets, which allow you to create dynamic command lines and parameters, this creates all kinds of problems for the parser, since it has to guess how to evaluate a line based on context and the evaluation priority of different parser features.

I would say that allowing /var without an = sign was a bad idea (I cannot remember the context of its implementation). However, it was probably implemented that way so that it would work like /set, which also does not need an equal sign. The = sign support was added later (I think) because of /var support for multiple variable definitions, each of which could have their own assignments leading to ambiguity if an = sign was not used.

Thanks for your comments on this topic everyone.

Page 2 of 2 1 2

Link Copied to Clipboard