adds code for semantic.check_program(). also ...

renames expr and stmt to check_*

unifies argument order of check_expr and check_stmt. env is now 2nd arg

check_stmt returns a stmt,env tuple.