mIRC Home    About    Download    Register    News    Help

Print Thread
#93679 11/08/04 02:24 PM
Joined: Aug 2003
Posts: 314
S
Sigh Offline OP
Fjord artisan
OP Offline
Fjord artisan
S
Joined: Aug 2003
Posts: 314
Found on mIRC 6.16, when $({,N) / $(},N) or $eval({,N) / $eval(},N) is evaluated it returns (N-1) (N-1) except when N = 0

//echo -a $({,1) * $(},2) * $eval({,3) * $eval(},4)

#93680 11/08/04 07:21 PM
Joined: Jul 2003
Posts: 742
Hoopy frood
Offline
Hoopy frood
Joined: Jul 2003
Posts: 742
so? if you didnt want { } evaluated dont put them in that code..


http://MTec89Net.com
irc.freenode.net #MTec89Net
#93681 11/08/04 08:14 PM
Joined: Aug 2003
Posts: 314
S
Sigh Offline OP
Fjord artisan
OP Offline
Fjord artisan
S
Joined: Aug 2003
Posts: 314
So you can explain why { or } evaluates once to give "0 0" and twice to give "1 1"? Let's wait for someone who can give a productive response

#93682 11/08/04 08:39 PM
Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
cool

evaluating { and } seem to trigger something deep in mircs parser

perhaps you just stumbled upon one of mircs perprocessor steps?

{ xxxxxxxxxx } turns into
0 0 xxxxxxxxxx 1 1
?

or maybe im crazy


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
#93683 12/08/04 05:12 AM
Joined: Dec 2002
Posts: 266
Z
Fjord artisan
Offline
Fjord artisan
Z
Joined: Dec 2002
Posts: 266
That is quite some funky stuff there.

Confirmed here, 6.16


You won't like it when I get angry.
#93684 12/08/04 11:00 AM
Joined: Jan 2003
Posts: 2,523
Q
Hoopy frood
Offline
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,523
I'd only add that this behaviour is very old, probably since $eval() was added. I always considered it to be one of those little parser quirks that I can live with.


/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com

Link Copied to Clipboard