The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Newsgroups: perl.perl6.language
From: l...@luqui.org (Luke Palmer)
Date: Sat, 26 Feb 2005 16:03:21 -0700
Local: Sat, Feb 26 2005 6:03 pm
Subject: Re: S06: Pairs as lvalues
Ingo Blechschmidt writes: It's the Int 13. Your example looks a lot like this one: > that's really convenient, but what will the following code do? > my $x = (a => 42); # $x is a Pair. > $x = 13; # Is $x now the Pair (a => 13) or > # the Int 13? my $x = [ 1, 2, 3 ]; And you could say that is an error because: [ 1, 2, 3 ] = 13; Is an error, but you'd be wrong. You see, in your example, the pair is I belive you could get the pair as an lvalue if you did: my (Pair $x) := (a => 42); Because the variable x is now *fundamentally* a pair; it has no Luke You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||