为什么要用引用啊?不加也可以啊
老师在catch()中用了引用,但是我试了一下,不用引用也可以啊
#include <iostream>using namespace std;void fun1(){	throw 1.1;}int main(){	try	{		fun1();	}	catch(double a)	{		cout<<a<<endl;	}		return 0;}
大神教教我……
老师在catch()中用了引用,但是我试了一下,不用引用也可以啊
#include <iostream>using namespace std;void fun1(){	throw 1.1;}int main(){	try	{		fun1();	}	catch(double a)	{		cout<<a<<endl;	}		return 0;}
大神教教我……
2019-03-10
举报