reftyped should accept undef