Will using goto cause memory leaks?

前端 未结 10 2172
迷失自我
迷失自我 2021-01-17 11:33

I have a program in which i need to break out of a large bunch of nested for loops. So far, the way most people have been telling me to do it is to use an ugly goto in my co

10条回答
  •  既然无缘
    2021-01-17 12:22

    Nope. Local variables do not need to be individually cleaned up. When the stack pops, all the local variables will go away right along with it.

提交回复
热议问题