Enforce immutable bindings

This adds some core classes for visiting and building scope chains.

Then it uses that for FreeVariableChecker, VariableBinder and new
check that validates consts.

Fixes #18