Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^2: Perl::Improved Volume 0, Number 1

by Corion (Patriarch)
on Sep 05, 2004 at 13:31 UTC ( #388604=note: print w/replies, xml ) Need Help??


in reply to Re: Perl::Improved Volume 0, Number 1
in thread Perl::Improved Volume 0, Number 1

I'm not convinced that the use of |...| to mean abs(...) doesn't break the existing grammar or introduces ugly whitespace dependency:

1+|a+b|+c+d|+1
can be naively parsed as
1+abs(a+(b|+c)+d)+1
or as
1+abs(a+b)+c+(d|+1)

because the ugly unary + is allowed, which breaks lots of things. Of course, introducing another slew of operator precedence could fix this, but I imagine it creates more confusion than the "clearer" syntax removes.

Replies are listed 'Best First'.
Re^3: Perl::Improved Volume 0, Number 1
by theorbtwo (Prior) on Sep 06, 2004 at 01:56 UTC

    Ah, thank you! My intuition told me that they conflicted, but I couldn't come up with a case -- largely because I forgot about unary +.

A reply falls below the community's threshold of quality. You may see it by logging in.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://388604]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (6)
As of 2022-01-19 18:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:












    Results (55 votes). Check out past polls.

    Notices?