Check function types, untested.