Top "Inline" questions

Use this tag for questions specifically about the effects of the inline keyword, together with the appropriate language tag.

inline vs __inline vs __inline__ vs __forceinline?

What are the differences between these four inline (key)words? inline, __inline, __inline__, __forceinline.

c++ inline keyword
Inline function v. Macro in C -- What's the Overhead (Memory/Speed)?

I searched Stack Overflow for the pros/cons of function-like macros v. inline functions. I found the following discussion: Pros …

c performance optimization macros inline
How can I create a piecewise inline function in MATLAB?

I have a function in MATLAB which takes another function as an argument. I would like to somehow define a …

matlab function inline piecewise
inline function linker error

I am trying to use inline member functions of a particular class. For example the function declaration and implementation without …

c++ inline linker-errors
Does constexpr imply inline?

Consider the following inlined function : // Inline specifier version #include<iostream> #include<cstdlib> inline int f(const …

c++ c++11 inline standards-compliance constexpr
Can I selectively (force) inline a function?

In the book Clean Code (and a couple of others I have come across and read) it is suggested to …

c++ optimization coding-style inline
What's the c++ inline class?

I accidentally found that the Clang compiler allows : inline class AAA { }; in C++. What's this? PS. I reported this to …

c++ class inline clang
Why is this F# code so slow?

A Levenshtein implementation in C# and F#. The C# version is 10 times faster for two strings of about 1500 chars. C#: 69 …

c# performance f# inline
C++ inlining class methods causes undefined reference

I'm getting a compiler error when I try to inline a method of one of my classes. It works when …

c++ inline
Should I define static inline methods in header file?

I've read about how it is usually best not to define anything in header files because redundant copies are made …

c++ static inline header-files