1 # Copyright (C) 2007-2009, Parrot Foundation.
6 This code example illustrates cloning with PMC strings. Simple copying
7 operations create two pointers to the same underlying memory structure.
8 A C<clone> operation actually creates two separate but identical
9 objects in memory. In this example, notice how C<$P1> and C<firstname>
10 both reference the same location in memory, but C<$P2> doesn't.
17 firstname = new ['String']
36 # vim: expandtab shiftwidth=4 ft=pir: