class Foo { public: Foo& operator=(const Foo&) = default; private: const int i = 0; };
Why is =default allowed? It compiles without errors. I think that =default should fail, since it is not possible to assign const to a variable?
What is really going on?
source share