Next:
How do I declare,
Up:
class and struct
Previous:
How do I put
How do I put the code of methods outside classes in a header file?
The code of a method specified in a header file must be declared
inline
. It means that when compiling, the calls to the method will all be replaced by the code of that method.
struct A { int a; A(); }; inline A::A() { /* ... */ };
Alexis Angelidis (PhD) 2005-01-11