Initial typechecker working