The result is in some ways similar to the use of the #define macro, but as, macros can lead to problems 9L0-509 since they aren't evaluated by the preprocessor. Inline functions do not suffer from the same problems.
If the inlined function is large, this replacement process (known for obvious reasons as "inlining") Pass4sure 9L0-402 can lead to "code bloat", leading to bigger (and hence usually slower) code. However, for small functions it can even reduce code size, particularly once a compiler's optimizer runs.
Note that the inlining process requires that the function's definition (including the code) must be available to the compiler. In particular, inline headers that are used from more than 9L0-509 one source file must be completely defined within a header file (whereas with regular functions that would be an error).
The most common way to designate that a function is inline is by the use of the inline keyword. 9L0-402 Exam One must keep in mind that compilers can be configured to ignore this keyword and use their own optimizations.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment