Last modified on 5 January 2009, at 23:59

Ada Programming/Pragmas/Inline


Ada Lovelace 1838.jpg

SummaryEdit

The pragma Inline specifies that a subprogram should be expanded inline when called in code.

ExampleEdit

function My_Function return Integer is begin
  return 1+2; -- A simple function suitable for inlining
end My_Function;
pragma inline(My_Function);
...
Some_Variable := My_Function; -- Will be expanded by compiler.

See alsoEdit

WikibookEdit