[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Deep Copy prototype
- From: Brad Olson <executive@...>
- Date: Wed, 7 May 2003 13:52:25 -0400
Luiz,
Thanks for the clarification. I meant to use:
if T == "string" then return string.gsub( A, "(.*)", "%1")
The string.gsub docs say: "Returns a copy of s in which..."
But if there truly aren't string duplicates, help me understand what string.gsub is returning?
On Tue, 6 May 2003 21:06:14 -0300, Luiz Henrique de Figueiredo wrote:
>>if T == "string" then return string.sub(A,1)
>
>Despite the way it looks, string.sub(A,1) does not produce a copy of
>the
>string A; there are no strings duplicates in Lua. The only values
>that can
>be copied are tables.
>--lhf
--Brad Olson
--executive@att.net
--05/07/2003 at 1:48:41 PM