You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
This is OK in 8.5:
expect1.3> set a {1 2 3}
1 2 3
expect1.4> expr {[lindex $a 1] in {2 3 4}}
1
But not OK in 8.4:
expect1.8> set a {1 2 3}
1 2 3
expect1.10> expr {[lindex $a 1] in {2 3 4}}
syntax error in expression "[lindex $a 1] in {2 3 4}": extra tokens at end of expression
while compiling
"expr {[lindex $a 1] in {2 3 4}}"
Is there a way to make the expression backward compatible in 8.4?
/WT
Alexandre Ferrieux
unread,
Feb 5, 2012, 6:50:05 PM2/5/12
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
Though the error message was not that clear (expr error reporting has
improved since then), the truth is just that "in" was not there yet :D
An equivalent working in older Tcls:
expr {[lsearch -exact {2 3 4} [lindex $a 1]]>=0}
-Alex
Why Tea
unread,
Feb 6, 2012, 4:07:55 AM2/6/12
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message