expand type tests to cope with dualvars