Fixed a serious bug with variable allocation. Now stored using reference counters like statements across the board. Will fix crashes when a function is defined but not used.
Added a much more precise CPU time measure.