found a couple more special forms
minor refactoring
use objects with nice methods (i.e. not just plain arrays and objects!) for state and log

move symbol counting to log