mIRC Homepage
Posted By: Chessnut Nested while loops bug - 19/05/08 06:58 PM
Apologies if this has been pointed out before, I'd be very surprised if it hasn't been, but I wasn't able to find it with a forum search.

The bug is with nested while loops on the same line of code. The following script fails when executed on a single line (terminates after the first iteration), but succeeds when spread out onto multiple lines:

Code:
alias test var %s 3 | while (%s) { var %a 3 | while (%a) { dec -s %a } | dec -s %s }


Fails, whereas:

Code:
test2 {
  var %s 3 
  while (%s) {
    var %a 3
    while (%a) {
      dec -s %a
    }
    dec -s %s 
  }
}


works as expected.

mIRC Version: 6.31
Posted By: Wims Re: Nested while loops bug - 19/05/08 07:15 PM
I'm sure i've seen a post concerning this bug, maybe not in "bug reports".
Posted By: RoCk Re: Nested while loops bug - 19/05/08 07:29 PM

Although I can't find it now because of a limit on search results, this has been reported and is known by Khaled. It's annoying that I couldn't find the thread because I was involved in the thread, but now it will only return max 100 results it seems. I don't think it's always been that way.
Posted By: Riamus2 Re: Nested while loops bug - 20/05/08 12:40 AM
Two different threads...
Posted By: argv0 Re: Nested while loops bug - 20/05/08 02:29 AM
Three if you count the original post referenced in the second link
Posted By: Riamus2 Re: Nested while loops bug - 20/05/08 03:07 AM
Oops, missed that link.
Posted By: Chessnut Re: Nested while loops bug - 20/05/08 12:59 PM
My bad, I didn't search for topics older than 3 years (didn't realise it had been an issue for so long).
Posted By: Riamus2 Re: Nested while loops bug - 20/05/08 04:52 PM
No problem. I was just linking to them so people could read up on what was said already. Not in complaint of not searching or anything like that. smile

I swear there was something more recent, though... within the past 6 months. Oh well.
Posted By: RRX Re: Nested while loops bug - 20/05/08 05:34 PM
Originally Posted By: Chessnut
My bad, I didn't search for topics older than 3 years (didn't realise it had been an issue for so long).

bromvlieg told you!
© mIRC Discussion Forums