dmd.inline

Performs inlining, which is an optimization pass enabled with the -inline flag.

The AST is traversed, and every function call is considered for inlining using inlinecost.d. The function call is then inlined if this cost is below a threshold.

Members

Functions

inlineCopy
Expression inlineCopy(Expression e, Scope* sc)

Perform the "inline copying" of a default argument for a function parameter.

inlineScanModule
void inlineScanModule(Module m)

Scan function implementations in Module m looking for functions that can be inlined, and inline them in situ.

Meta

Suggestion Box / Bug Report