> Out of curiosity, how does the word
> "assign" imply that it morphs an
> existing value, and how does the word
> "set" imply that it copies a pointer?
Well, I suppose "set" was chosen just because
that seems to be the standard name for an
operation that copies a pointer. Then "assign"
was chosen
Togos <[EMAIL PROTECTED]> wrote:
>> Anyway:
>>
>> assign Px, {Iy,Sy,Ny}
>>
>> are not needed IMHO, these end up as
>> set__native and are identical
>> to set Px, {Iy,Sy,Ny}.
> If you want to get rid of opcode aliases,
> perhaps it would be better to get rid of
> the extra 'set's.
Cleanup (get r
TOGoS:
# Personally, I would like "=" to mean 'set', and
# maybe "<-" do 'assign'.
I usually think of registers as variables with fixed names, so the Perl
6 part of my brain suggests:
$P0 = $P1 #assign
$P0 := $P1 #set
--Brent Dax <[EMAIL PROTECTED]>
Perl and Parrot hac
> Anyway:
>
> assign Px, {Iy,Sy,Ny}
>
> are not needed IMHO, these end up as
> set__native and are identical
> to set Px, {Iy,Sy,Ny}.
Yes, but as we were discussing in the
Set vs. Assign thread, it makes more sense
to call them 'assign', as it morphs the
existing value (as 'assign Px, Py' does)
Brent Dax wrote:
>
> TOGoS:
> # Personally, I would like "=" to mean 'set', and
> # maybe "<-" do 'assign'.
>
> I usually think of registers as variables with fixed names, so the Perl
> 6 part of my brain suggests:
>
> $P0 = $P1 #assign
> $P0 := $P1 #set
Which is wh
Togos <[EMAIL PROTECTED]> wrote:
> if you assign an integer to a PerlString, it's
> still a PerlString.
No more. I don't know, if its correct. But the behavior now seems more
natural to me:
new P1, .PerlInt
set P1, 42
new P0, .PerlUndef
assign P0, P1 # LHS is PerlInt now
The dest has to
Leopold Toetsch wrote:
>
> I hopefully got the semantics of assign Px,Py right now. The LHS gets
> the value of RHS, eventually morphing itself to the source type.
>
> Anyway:
>
>assign Px, {Iy,Sy,Ny}
>
> are not needed IMHO, these end up as set__native and are identical
> to set Px, {Iy,
Togos wrote:
>
> > Anyway:
> >
> > assign Px, {Iy,Sy,Ny}
> >
> > are not needed IMHO, these end up as
> > set__native and are identical
> > to set Px, {Iy,Sy,Ny}.
>
> Yes, but as we were discussing in the
> Set vs. Assign thread, it makes more sense
> to call them 'assign', as it morphs the
> e