On 3/30/20 1:06 PM, Pham wrote:
Will it be the same if using "is", the reason is for function that use "nothrow" attribute?if (cc.classinfo is typeid(CC))I don't really understand the question about "nothrow". -Steve
void main()
{
static class Foo { int i; }
static bool checkFoo() nothrow
{
// error when compile
//return typeid(Foo) == Foo.classinfo;
// ok when compile
return typeid(Foo) is Foo.classinfo;
}
checkFoo();
}
