cleanup last merge, some cosmetic changes;
revert “Push references to variables instead of values from
addVariable”, I still need to think about the better way