add pet_inliner
A pet_inliner keeps track of assignments of (parts of) actual arguments
to temporary variables and substitutions of the formal arguments
by (expressions containing) these temporary variables.
It then applies the substitutions to a tree corresponding to
the body of the called functions and places the result in
a block after the assignments.
In case of array arguments, it's the arguments of the array access
expression that are assigned to temporary variables and these temporary
variables replace the original arguments in the array access expression
that is used as a substitution for the corresponding formal argument.
The inliner is intended to be used on an unevaluated pet_tree.
The use of assignments before the inlined tree ensures that
the correct values are used. In those cases where the assignments
can be propagated to the reads of the corresponding variables,
it will be taken care of by the general propagation mechanism
of pet_context.
The use of the inliner will follow in a subsequent commit.
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>