[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Implementing data structures with closures and coroutines
- From: "Soni L." <fakedme@...>
- Date: Tue, 19 Jul 2016 18:09:25 -0300
On 19/07/16 06:06 PM, Soni L. wrote:
Hi list,
I'd like to implement data structures using nothing but closures and
coroutines, including setmetatable (or, in this project,
setmetaclosure) and getmetatable (or, in this project,
getmetaclosure). These would be wrappers around the stdlib's
setmetatable and getmetatable.
Combining varargs and coroutines makes efficient stacks that are very
fast for push/pop operations, but very slow for other operations, thus
they are unsuitable as a general-purpose data structure.
How can I make general-purpose data structures without tables?
Clarification: This isn't a serious project, it's something I wanna do
because I can.
--
Disclaimer: these emails may be made public at any given time, with or without reason. If you don't agree with this, DO NOT REPLY.