4 ms·
Might be worth mentioning Tcl in this context, as it uses reference counting for the GC [1]. It also doesn't allow circular data structures, which are quit har
by manveru 15y ago
Might be worth mentioning Tcl in this context, as it uses reference counting for the GC [1].
It also doesn't allow circular data structures, which are quit hard to implement if all you have are strings anyway.
[1]: http://wiki.tcl.tk/3096 http://wiki.tcl.tk/3096
- zerohp 15y agoPerl also uses reference counting, and cyclical data structures cause memory leaks unless you explicitly decrease the reference count with the weaken function from Scalar::Util.
- IgorPartola 15y agoAnd Python. AFAIK, there are no plans to fix it at this point. Also Python is notorious for allocating lots of small objects.
- LeonidasXIV 15y agoThough it does throw away unused cyclic dependencies, so you don't have to do the same trickery as in Perl.
- stonemetal 15y agoPython has a mark and sweep garbage collector(since 2.0) to catch that which reference counting misses. You can disable it if you know you don't make any cyclical objects.
- pnathan 15y agoI've done minor amounts of text analysis in Python. It is a memory pig. I was shocked. Anything remotely like a non-trivial dataset should not be run in pure Python, based on my experience.