
The Explicit Keyword
A constructor taking a single argument is by default an implicit conversion operator: class C { int I; //… public: C(int i);//constructor and implicit conversion operator //as well }; void f() { C c(0);c = 5; //implicit conversion of 5 to a C object and //then assignment } The compiler