终止被递归调用 [英] terminate called recursively

查看:4593
本文介绍了终止被递归调用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

据我所知, terminate()在异常处理有问题时被调用(通常只是没有被捕获)。
我得到的只是一个错误行终止调用

As far as I know, terminate() is called when there is some problem with exception handling(usually it's just not caught). What I got is just one error line terminate called recursively.

googling一段时间后,我发现了很多例子

After googling for some time I found a lot of examples of

terminate called after throwing an instance of ... terminate called recursively

但这不是我的情况。由于我没有这个异常类型的提示,我想知道这个终止调用递归调用意味着自己。

But it's not my case. As I don't have this hint about the exception type, I'm wondering what does this terminate called recursively mean by itself.

对不起,我无法提供代码,所以任何猜测都将有所帮助。
我使用g ++ 4.5.2在Ubuntu 11.04下编译。

Sorry I can't provide the code, so any guess will be helpful. I'm compiling with g++ 4.5.2 under Ubuntu 11.04.

非常感谢,
Alex。

Thanks a lot, Alex.

推荐答案

可能是一些代码抛出一个异常你不捕获,这意味着 terminate 将被调用。终止程序意味着可以调用对象析构函数,如果其中一个有一个异常,那么 terminate 将被称为递归。

Could be that some code throws an exception you don't catch, which means terminate will be called. Terminating the program means that object destructors might be called, and if there is an exception in one of them then terminate will be called "recursively".

这篇关于终止被递归调用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆