[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Implementing data structures with closures and coroutines
- From: "Soni L." <fakedme@...>
- Date: Tue, 19 Jul 2016 18:06:19 -0300
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?
--
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.