[BTW, I'm being horrible and replying to this on perl6-internals, since it's important] At 09:16 AM 12/17/2001 -0800, Brent Dax wrote: >Dan Sugalski: ># However, that's not appropriate here--set P0, P1 should just copy the ># pointer from P1 to P0. Actually stuffing the value of the PMC ># pointed to by ># P1 into the one pointed to in P0 should be done with a different op. > >No offense intended Dan, but from what I've seen you're alone in that >opinion. That may not matter, since you're the internals designer :^),
Ah, the joys of Supreme Executive Power! Bwahahahahahaha! ;-P Well, that and an ego the size of a largish Jovian moon. >but please give at least some consideration to the fact that most people >on p6i seem to think the copy functionality is appropriate. Copy functionality is certainly useful, I just don't think set's the right thing for it. We really have three separate but related needs: *) Shallow register copy. (set) This just copies a value from one register to another, or sticks a pointer to a constant into a register. *) Deep copy (assign). This takes the contents of one structure (string or PMC) and stuffs it inside an existing string or PMC. (So the string or PMC structure remains, but the buffer is changed) *) Clone with toss (clone). This takes a register pointing to a string or PMC, creates a new one that's identical to it, and puts the pointer to it in the destination register. I can draw some pictures if that'll help. Dan --------------------------------------"it's like this"------------------- Dan Sugalski even samurai [EMAIL PROTECTED] have teddy bears and even teddy bears get drunk