Chapter 25. inline Redux

Difficulty: 7

QuickWhen is inlining performed? And is it possible to write a function that can be guar-anteed never to be inlined? In this Item, we'll consider the many and varied opportunities for inlining, including many that are likely to surprise you. The answers, stated simply, are, “It's never too late, and nothing is impossible…”

Solution

Which answer did you pick for Question 2? If you picked (a) or (b), you're not alone. Those are the most common answers, and you might have ...

Get Exceptional C++ Style 40 New Engineering Puzzles, Programming Problems, and Solutions now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.