Skip to content

Commit

Permalink
[subs] Fixed "order-burger" code example
Browse files Browse the repository at this point in the history
Concatenation op (~) has tighter precedence than Conditional op (??!!)
  • Loading branch information
Util committed Jun 9, 2010
1 parent 1eb7efd commit 54a4228
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/subs-n-sigs.pod
Expand Up @@ -266,7 +266,7 @@ parameter bind to an undefined value if no argument is passed:

sub order-burger($type, $side?) {
say "I'd like a $type burger" ~
defined($side) ?? " with a side of $side" !! "";
( defined($side) ?? " with a side of $side" !! "" );
}

order-burger("triple bacon", "deep fried onion rings");
Expand Down

0 comments on commit 54a4228

Please sign in to comment.