16 lines
273 B
Text
16 lines
273 B
Text
|
|
function deep_copy(object o)
|
||
|
|
object res
|
||
|
|
if atom(o) then
|
||
|
|
res = o
|
||
|
|
else
|
||
|
|
res = repeat(' ',length(o))
|
||
|
|
for i=1 to length(o) do
|
||
|
|
res[i] = deep_copy(o[i])
|
||
|
|
end for
|
||
|
|
end if
|
||
|
|
return res
|
||
|
|
end function
|
||
|
|
|
||
|
|
object c = deep_copy(b)
|
||
|
|
?c
|