Closed
Description
The type inference module includes a "transactional" component that allows unifications to roll back in the case of failure. This is used in various places but one notable place is in the resolution of impls, where we must look for all possible matches. However, integral type variables never roll back. This is simple to fix but it exposes another problem, which is that we are not properly forcing integral type variables to int in method calls. As a side effect, something like this:
5.times { }
yields an error because here 5 could be int
, uint
, etc.