If I do
struct A{};
struct C:private A{};
typedef char (&yes)[1];
typedef char (&no)[2];
template
struct Host
{
operato
Do you need something that can be evaluated at runtime, or will a simple compile time error suffice?
struct A {};
struct B : private A {};
int main()
{
B b;
// gives error C2243: 'static_cast' : conversion from 'B *' to 'A &' exists, but is inaccessible
A& a = static_cast(b);
return 0;
}