What\'s the difference between inline function and then main like so:
inline double cube(double side)
{
return side * side * side;
}
int main( )
{
cu
Performance wise, they are all the same since inline is just a hint for the compiler. If the separation of declaration/definition is used and the definition is on a different translation unit, then it will be harder for the compiler to inline it (but there are implementations that do so).
A difference with making a function inline or not is that the linker will not complain if it sees the same inline definition for a function more than once.