What is "inline" function?

inline keyword before name of the function allows the compiler to insert a copy of the function body into each place the function is called. Therefore, the size of the code is increasing, but speed of execution is also increasing. You should mention that there are circumstances (e.g. recursive functions) when compiler is allowed to ignore inline keyword.

No comments: