下面代码错误的是:structA{A(int){}operatorbool...
发布于 2022-03-03 15:18:00
下面代码错误的是:
struct A
{
A(int) { }
operator bool() const { return true }
}
struct B
{
explicit B(int) {}
explicit operator bool() const { return true }
}
A a1(1)B b1(1)
登录后免费查看答案
关注者
0
被浏览
3