fix some type annotations for recent released compiler