By uxcn
VLAs in reality are just as dangerous as allocating from the heap. I would agree not everything should be allocated on the stack, but you can overflow the heap just as you can overflow the stack.
Unless people are completely irresponsible, they query the stack limit and subtract the current stack bound before using the heap for large objects. Freeing memory is even simpler than using the heap, and faster as well. I think the only real concern is people being responsible about using them.
: https://news.ycombinator.com/item?id=10281944
uxcn comments on "Rejuvenating the Microsoft C/C++ Compiler"
No comments:
Post a Comment