Damian Conway skribis 2005-02-20 11:28 (+1100):
> >According to S03, ~ is tighter than x, while in Perl 5, . was looser
> >than x.
> No. According to S03, *unary* ~ is tighter than x. *Binary* ~ is looser:
> >symbolic unary ! + - ~ ? * ** +^ ~^ ?^ \
> >multiplicative * / % x xx +&
Juerd wrote:
According to S03, ~ is tighter than x, while in Perl 5, . was looser
than x.
No. According to S03, *unary* ~ is tighter than x. *Binary* ~ is looser:
symbolic unary ! + - ~ ? * ** +^ ~^ ?^ \
multiplicative * / % x xx +& +<< +>> ~& ~<< ~>>
additive+ - ~
According to S03, ~ is tighter than x, while in Perl 5, . was looser
than x.
This can be surprising in things like
"@" x 75 ~ $zap
Which has to be written as
("@" x 75) ~ $zap
in order to make sense.
Was this intentional? What is the rationale?
Juerd
--
http://convolution.nl/maak_j