mIRC Home    About    Download    Register    News    Help

Print Thread
Page 2 of 2 1 2
Re: Script parsing bug? [Re: NaquadaServ] #178125 05/06/07 02:16 PM
Joined: Dec 2002
Posts: 2,962
S
starbucks_mafia Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 2,962
So because mIRC supports some bad habits you think it should support more?

It may be awkward to remove the current allowances due to backwards compatability, but that's absolutely no reason to encourage more poor code by making mIRC play parser-detective.

You seem to have some kind of pathological phobia of errors. There's nothing wrong with them. They're downright vital in fact. When code's meaning isn't clear - that's an error. Trying to sweep them under the carpet with guesswork doesn't help anybody.


Spelling mistakes, grammatical errors, and stupid comments are intentional.
Re: Script parsing bug? [Re: NaquadaServ] #178132 05/06/07 05:20 PM
Joined: Sep 2005
Posts: 2,876
H
hixxy Offline
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,876
Originally Posted By: NaquadaServ
To all three prior replies: I'm sorry, I'm not going to teach a course in logic here.


Good. You're not qualified.

Re: Script parsing bug? [Re: NaquadaServ] #178137 05/06/07 06:37 PM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
starbucks_mafia is right. Bad coding practices shouldn't be encouraged even if some bad practices are already possible in mIRC. Write code using proper syntax and you'll save everyone a lot of headaches. I absolutely hate trying to debug code that is written using invalid syntax or written in such a way as to make it difficult to read clearly (such as tons of commands on a single line using pipes). It's just not helpful to anyone.


Invision Support
#Invision on irc.irchighway.net
Re: Script parsing bug? [Re: Riamus2] #178146 05/06/07 08:16 PM
Joined: Dec 2002
Posts: 580
N
NaquadaServ Offline OP
Fjord artisan
OP Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 580
Proper syntax is flawed, all I'm saying is make it consistent. Eliminate the sometimes is does, sometimes it doesn't situations.

Thankfully the decision is not up to all of you, it Khaled's decision. I assume (unlike I can for the rest of you) that he actually has a computer science degree, and can fully understand my argument.


Last edited by NaquadaServ; 05/06/07 08:19 PM.

NaquadaBomb
www.mirc-dll.com
Re: Script parsing bug? [Re: NaquadaServ] #178148 05/06/07 08:20 PM
Joined: Dec 2002
Posts: 2,013
R
RoCk Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Dec 2002
Posts: 2,013
I can understand that it should be consistent, but if anything were to be changed, it should go the opposite way from where you want it to go.

~ Edit ~

lmao .. so now everyone else is stupid and uneducated because they don't see things your way?

Last edited by RoCk; 05/06/07 08:23 PM.
Re: Script parsing bug? [Re: RoCk] #178161 05/06/07 09:08 PM
Joined: Dec 2002
Posts: 580
N
NaquadaServ Offline OP
Fjord artisan
OP Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 580
Originally Posted By: RoCk
I can understand that it should be consistent, but if anything were to be changed, it should go the opposite way from where you want it to go.

I agree, but do you honestly think that (killing backwards compatibility) would go over well here? I'm arguing the only backwards compatible method to resolve these inconsistencies.

Originally Posted By: RoCk
lmao .. so now everyone else is stupid and uneducated because they don't see things your way?


No, not stupid, far from it, just less skilled/experienced. I didn't say everyone, only commenting on those people that responded earlier to this thread. It's also an assumption, nothing more.

Last edited by NaquadaServ; 05/06/07 09:17 PM.

NaquadaBomb
www.mirc-dll.com
Re: Script parsing bug? [Re: NaquadaServ] #178163 05/06/07 09:16 PM
Joined: Sep 2005
Posts: 2,876
H
hixxy Offline
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,876
It's a minor inconsistency that has gone almost unnoticed for years because nobody wants to write such tacky code. Fixing this inconsistency will not really benefit the users of the program, but it will make code harder to debug for people unaware of the correct syntax. It may be an inconsistency, but it's a useful one.

Re: Script parsing bug? [Re: NaquadaServ] #178166 05/06/07 09:20 PM
Joined: Dec 2002
Posts: 2,962
S
starbucks_mafia Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 2,962
Quote:

I agree, but do you honestly think that (killing backwards compatibility) would go over well here? I'm arguing the only backwards compatible method to resolve these inconsistencies.

The fundamental flaw in your logic here is that most people would rather see less scope for poor code at the cost of letting the inconsistency remain. Personally I'd be quite happy to see backwards compatability broken in this case to enforce the use of () or {}.

But that's probably just my lack of skill and experience talking.


Spelling mistakes, grammatical errors, and stupid comments are intentional.
Re: Script parsing bug? [Re: starbucks_mafia] #178167 05/06/07 09:30 PM
Joined: Dec 2002
Posts: 580
N
NaquadaServ Offline OP
Fjord artisan
OP Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 580
Originally Posted By: starbucks_mafia
Personally I'd be quite happy to see backwards compatability broken in this case to enforce the use of () or {}.

At least I partially got through to someone.

Originally Posted By: starbucks_mafia
But that's probably just my lack of skill and experience talking.

Love the sarcasm... smile


NaquadaBomb
www.mirc-dll.com
Re: Script parsing bug? [Re: NaquadaServ] #178193 06/06/07 03:30 AM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
Considering that I do have a degree and have a very good understanding of computers and programming and have even taught both, I think your assumption is invalid. And I'm sure the same can be said for most others here as well (especially those who are regular helpers).

Now. Consistancy is a good thing. However, as has been mentioned, you should *not* make it consistant by allowing more bad coding styles. That is a bad argument, pure and simple. Forcing only valid syntax (ie. good coding styles) is not a bad thing.

So the question comes up... should we break all of the scripts that use bad coding that currently work because mIRC lets some things slip by so that coding is consistant -- you either use valid code or it won't work, or do we leave things as they are so that no scripts are broken, but coding styles cannot deteriorate further than they already are.

That's a difficult question because you don't want to break as many scripts as those changes would break. However, mIRC has made changes that forced better coding (6.20 did that) and it did break some scripts that weren't coded correctly. Of course, those changes were to actual errors rather than dropping sets of ()'s and {}'s, so forcing people to fix those was more valid than forcing them to add in all of the missing ()'s and {}'s. Even so, it is a precedent to forcing valid code. The question remains as to wheter Khaled will do that. Personally, I think valid syntax should always be required. It makes debugging a LOT easier and it also makes for less chance of producing errors.

In any case, I think everyone here (and most likely Khaled as well) will agree that mIRC should *not* allow *more* bad coding, no matter what. The real question is whether or not to force good coding for the items that can currently be coded "badly" and still work. You'd have support for that suggestion, but you won't have support for lowering the coding syntax requirements.


Invision Support
#Invision on irc.irchighway.net
Re: Script parsing bug? [Re: Riamus2] #178196 06/06/07 07:04 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
RusselB nominates Riamus for President laugh You've got my vote

Re: Script parsing bug? [Re: Riamus2] #178197 06/06/07 08:10 AM
Joined: Sep 2005
Posts: 2,876
H
hixxy Offline
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,876
I say leave it as it is. Using only one set of brackets isn't even what I'd call 'bad' coding, as it's still very clear what you're trying to do.

Code:
if x == y { do this }
if (x == y) do this
if (x == y) { do this }


There's absolutely no ambiguity in any of those statements. In this however:

Code:
if x == y do this


There is.

Re: Script parsing bug? [Re: NaquadaServ] #178199 06/06/07 08:54 AM
Joined: Jul 2003
Posts: 655
Om3n Offline
Fjord artisan
Offline
Fjord artisan
Joined: Jul 2003
Posts: 655
Originally Posted By: NaquadaServ
Originally Posted By: starbucks_mafia
Personally I'd be quite happy to see backwards compatability broken in this case to enforce the use of () or {}.

At least I partially got through to someone.


You are assuming nobody else had these thoughts, which is far from accurate. The thing is, your posts were suggesting the opposit.

Personally, i'd prefer to see the forced use of correct syntax (braces etc), rather than accomodate less use of correct syntax.

I doubt this will be changed either way, because BOTH way would break some scripts. Granted that forcing the use of braces in all cases would break more, there would still be a few that the other way would break, or alter the behavior of, due to the underlying logic change.

As for your rediculas assumptions about CS degrees and lack of understanding, you were wrong.


"Allen is having a small problem and needs help adjusting his attitude" - Flutterby
Re: Script parsing bug? [Re: hixxy] #178203 06/06/07 12:25 PM
Joined: Dec 2002
Posts: 2,013
R
RoCk Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Dec 2002
Posts: 2,013
Ditto here hixxy, I think that unless the syntax is going to be enforced 100%, there has to be a line (tolerance). The example given in the OP of this thread not only exceeded that line, but kicked the lines dog, insulted its mother and then complained because the line didn't say thank you. The line is fine where it is.

Re: Script parsing bug? [Re: hixxy] #178204 06/06/07 01:41 PM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
Originally Posted By: hixxy
I say leave it as it is. Using only one set of brackets isn't even what I'd call 'bad' coding, as it's still very clear what you're trying to do.


That's why I put quotes around "badly". I think leaving it as-is would be fine. Making it less strict would be bad. Making it more strict wouldn't necessarily be bad, but would break enough scripts that I doubt it would happen. Besides, the current method has worked perfectly fine for a long time, so there really isn't a reason to change it, so I agree with you. smile


Invision Support
#Invision on irc.irchighway.net
Page 2 of 2 1 2