Extend cerl_trees:mapfold with a 'pre-order' operation
Extend cerl_trees:mapfold with a 'pre-order' operation

When manipulating Core Erlang trees it may be useful to perform some
operation when a node is visited, before inspecting children nodes. The
definition of cerl_tree:mapfold/3 does not allow that, as it applies the
given function only after all the recursive calls on the children nodes
have been completed.

This patch adds a new argument to mapfold: a function that is applied when
a node is first entered.

As an example of its use, consider the case where one wants to move a
'call' node earlier, by adding 'let' node and replacing the 'call' node
with the defined variable. The name of that variable must be specified
before one traverses the inner tree (especially if such replacements can be
nested).

RaimoNiskanen/otp,vinoski/otp,legoscia/otp,ahmedshafeeq/otp,massemanet/otp,g-andrade/otp,kvakvs/otp,mikpe/otp,emile/otp,weisslj/otp,ferd/otp,goertzenator/otp,g-andrade/otp,mikpe/otp,RaimoNiskanen/otp,bsmr-erlang/otp,vinoski/otp,vladdu/otp,ferd/otp,uabboli/otp,neeraj9/otp,cobusc/otp,emile/otp,psyeugenic/otp,lemenkov/otp,lrascao/otp,goertzenator/otp,lemenkov/otp,uabboli/otp,lemenkov/otp,RaimoNiskanen/otp,goertzenator/otp,RaimoNiskanen/otp,tuncer/otp,g-andrade/otp,lemenkov/otp,fenollp/otp,vladdu/otp,kvakvs/otp,emile/otp,weisslj/otp,jj1bdx/otp,matwey/otp,bjorng/otp,lemenkov/otp,massemanet/otp,dgud/otp,massemanet/otp,g-andrade/otp,RoadRunnr/otp,isvilen/otp,vladdu/otp,dumbbell/otp,matwey/otp,jj1bdx/otp,ahmedshafeeq/otp,falkevik/otp,uabboli/otp,kvakvs/otp,getong/otp,release-project/otp,legoscia/otp,lightcyphers/otp,RoadRunnr/otp,massemanet/otp,vinoski/otp,release-project/otp,bernardd/otp,potatosalad/otp,falkevik/otp,saleyn/otp,RaimoNiskanen/otp,fenollp/otp,uabboli/otp,isvilen/otp,erlang/otp,basho/otp,falkevik/otp,emile/otp,lrascao/otp,vinoski/otp,falkevik/otp,cobusc/otp,release-project/otp,uabboli/otp,electricimp/otp,massemanet/otp,bugs-erlang-org/otp,emacsmirror/erlang,saleyn/otp,lemenkov/otp,rlipscombe/otp,bugs-erlang-org/otp,tuncer/otp,potatosalad/otp,emacsmirror/erlang,lightcyphers/otp,bsmr-erlang/otp,bernardd/otp,ahmedshafeeq/otp,g-andrade/otp,RoadRunnr/otp,dgud/otp,cobusc/otp,potatosalad/otp,basho/otp,release-project/otp,g-andrade/otp,dumbbell/otp,vinoski/otp,psyeugenic/otp,rlipscombe/otp,isvilen/otp,bjorng/otp,kvakvs/otp,legoscia/otp,ferd/otp,bugs-erlang-org/otp,vinoski/otp,release-project/otp,legoscia/otp,psyeugenic/otp,bernardd/otp,jj1bdx/otp,isvilen/otp,bjorng/otp,uabboli/otp,vladdu/otp,getong/otp,lemenkov/otp,bsmr-erlang/otp,massemanet/otp,mikpe/otp,goertzenator/otp,saleyn/otp,ahmedshafeeq/otp,lrascao/otp,weisslj/otp,matwey/otp,tuncer/otp,RaimoNiskanen/otp,ferd/otp,fenollp/otp,rlipscombe/otp,saleyn/otp,getong/otp,RaimoNiskanen/otp,legoscia/otp,goertzenator/otp,goertzenator/otp,bernardd/otp,weisslj/otp,emacsmirror/erlang,neeraj9/otp,tuncer/otp,lrascao/otp,massemanet/otp,falkevik/otp,basho/otp,dumbbell/otp,RoadRunnr/otp,getong/otp,jj1bdx/otp,weisslj/otp,bjorng/otp,neeraj9/otp,psyeugenic/otp,isvilen/otp,goertzenator/otp,release-project/otp,aboroska/otp,saleyn/otp,getong/otp,electricimp/otp,dumbbell/otp,falkevik/otp,emacsmirror/erlang,mikpe/otp,erlang/otp,psyeugenic/otp,isvilen/otp,matwey/otp,cobusc/otp,RaimoNiskanen/otp,tuncer/otp,aboroska/otp,g-andrade/otp,potatosalad/otp,cobusc/otp,vinoski/otp,cobusc/otp,RaimoNiskanen/otp,g-andrade/otp,electricimp/otp,matwey/otp,rlipscombe/otp,lightcyphers/otp,lrascao/otp,bjorng/otp,bernardd/otp,bernardd/otp,basho/otp,mikpe/otp,tuncer/otp,emile/otp,aboroska/otp,rlipscombe/otp,basho/otp,rlipscombe/otp,legoscia/otp,kvakvs/otp,fenollp/otp,dumbbell/otp,tuncer/otp,isvilen/otp,vladdu/otp,bsmr-erlang/otp,g-andrade/otp,psyeugenic/otp,fenollp/otp,ahmedshafeeq/otp,dgud/otp,bugs-erlang-org/otp,uabboli/otp,electricimp/otp,lightcyphers/otp,neeraj9/otp,dumbbell/otp,bsmr-erlang/otp,getong/otp,bsmr-erlang/otp,electricimp/otp,vinoski/otp,RoadRunnr/otp,emile/otp,vladdu/otp,emacsmirror/erlang,aboroska/otp,vladdu/otp,aboroska/otp,neeraj9/otp,fenollp/otp,ferd/otp,rlipscombe/otp,mikpe/otp,erlang/otp,fenollp/otp,jj1bdx/otp,erlang/otp,dumbbell/otp,basho/otp,jj1bdx/otp,rlipscombe/otp,getong/otp,matwey/otp,release-project/otp,goertzenator/otp,falkevik/otp,bjorng/otp,electricimp/otp,massemanet/otp,ferd/otp,bsmr-erlang/otp,falkevik/otp,electricimp/otp,potatosalad/otp,release-project/otp,dgud/otp,bjorng/otp,ferd/otp,aboroska/otp,dgud/otp,goertzenator/otp,lightcyphers/otp,falkevik/otp,kvakvs/otp,dgud/otp,kvakvs/otp,dumbbell/otp,kvakvs/otp,dgud/otp,bugs-erlang-org/otp,psyeugenic/otp,saleyn/otp,erlang/otp,lightcyphers/otp,kvakvs/otp,erlang/otp,ahmedshafeeq/otp,mikpe/otp,potatosalad/otp,vinoski/otp,bernardd/otp,bugs-erlang-org/otp,ferd/otp,emacsmirror/erlang,bernardd/otp,lightcyphers/otp,dumbbell/otp,emile/otp,saleyn/otp,getong/otp,basho/otp,vladdu/otp,ahmedshafeeq/otp,aboroska/otp,neeraj9/otp,lrascao/otp,jj1bdx/otp,potatosalad/otp,aboroska/otp,basho/otp,RoadRunnr/otp,vinoski/otp,potatosalad/otp,weisslj/otp,matwey/otp,basho/otp,uabboli/otp,isvilen/otp,mikpe/otp,saleyn/otp,jj1bdx/otp,g-andrade/otp,tuncer/otp,dgud/otp,weisslj/otp,emacsmirror/erlang,emacsmirror/erlang,bsmr-erlang/otp,erlang/otp,lrascao/otp,bjorng/otp,massemanet/otp,weisslj/otp,RoadRunnr/otp,bsmr-erlang/otp,lrascao/otp,bugs-erlang-org/otp,RoadRunnr/otp,ahmedshafeeq/otp,rlipscombe/otp,dumbbell/otp,cobusc/otp,tuncer/otp,emacsmirror/erlang,aboroska/otp,ahmedshafeeq/otp,legoscia/otp,mikpe/otp,bjorng/otp,matwey/otp,potatosalad/otp,bjorng/otp,jj1bdx/otp,erlang/otp,release-project/otp,emile/otp,legoscia/otp,weisslj/otp,lrascao/otp,bernardd/otp,jj1bdx/otp,emacsmirror/erlang,isvilen/otp,isvilen/otp,legoscia/otp,neeraj9/otp,saleyn/otp,RoadRunnr/otp,uabboli/otp,potatosalad/otp,fenollp/otp,fenollp/otp,emile/otp,vladdu/otp,psyeugenic/otp,mikpe/otp,getong/otp,erlang/otp,ferd/otp,electricimp/otp,electricimp/otp,neeraj9/otp,getong/otp,dgud/otp,lemenkov/otp,cobusc/otp,dgud/otp,matwey/otp,erlang/otp,rlipscombe/otp,bugs-erlang-org/otp,lightcyphers/otp