Usually I prefer to have totally split declarations and definitions, therefore, I tend to define inline methods in the .cpp
I just hope that the link optimizer inline it when it is used in a different compilation unit.
My questions are:
- Is it really discouraged to inline in cpp if I know my linker support inline at link time?
- What should I do if I want to call the function from another library?(Will it work?)