Inline Functions in C++

Calling a function has a performance penalty because you have to create variables, specify scope, pause the current variables and push data onto the call stack, just to name a few reasons. C++ allows you to define an inline function, which should be short, to improve the performance. In doing so, the compiler will actually…