correctly handle generics
quick fix for refining parameter lists
move stuff to FindUtils
update typechecker with new error codes