News for hackers. Stuff that matters.
Re:Memory management in C programs by aidenn0 on Tuesday March 18, 2014 @06:05PM (#7425354)
Though not what it's designed for, halloc[1] Is similar to what you are talking about; if each function manually allocated its locals with halloc, and used the parent function as the parent allocator, then you would get an unbroken tree, and would free all the children upon returning from the function that had called setjmp().

[1] http://swapped.cc/#!/halloc

Re:Memory management in C programs by dllthomas on Tuesday March 18, 2014 @08:28PM (#7426076)
Yeah, for sure. Wouldn't allow for cleanup of non-memory resources, though, so far as I can tell.