We all know that things like this are valid in c++:
const T &x = T();
while:
T &x = T();
is not.<
You just got lucky. Changing B::b to this:
void b() { int i = rand(); int j = rand(); cout << _a << endl; }
prints out random numbers.