fix Issue 9619 - Failed struct field typeof in inner function