怎么样判断一个变量或内存是在栈内还是在堆内呢??
求求
求求

解决方案
40
http://stackoverflow.com/questions/13719563/how-to-find-if-a-variable-is-allocated-in-stack-or-heap
http://stackoverflow.com/questions/16709946/how-to-determine-if-returned-pointer-is-on-the-stack-or-heap
参照上面两个帖子,基本没有通用方法来判断;
http://stackoverflow.com/questions/16709946/how-to-determine-if-returned-pointer-is-on-the-stack-or-heap
参照上面两个帖子,基本没有通用方法来判断;