C++ allows you to declare variables wherever you need them, thus enabling immediate initializations. A good example is a loop counter. It can (and should) be declared inside a for-statement:
Not every function that is declared inline can actually be inlined by the compiler. A function that has local variables, loops, or an extensive amount of code cannot be inlined