update typechecker with bugfix for #527