Modify the type that has thus far been inferred for a tree.
Modify the type that has thus far been inferred for a tree. All this should do is add annotations.
Returns an adapted type for a return expression if the method's result type (pt) is a CPS type.
Returns an adapted type for a return expression if the method's result type (pt) is a CPS type.
Otherwise, it returns the default
type (typedReturn
passes NothingTpe
).
A return expression in a method that has a CPS result type is an error unless the return is in tail position. Therefore, we are making sure that only the types of return expressions are adapted which will either be removed, or lead to an error.