| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Compiling scala.math.BigDecimal and scala.math.BigInteger shows a problem.
The conversion `int2bigInt` is not applicable to a Byte because `Byte -> Int`
requires another implicit conversion.
We fix that by using a new method relaxed_<:< for implicit compatibility checks,
which always admits numeric widenings.
This leads to another problem. Now the conversions
implicit def byteToInt(x: Byte): Int
implicit def byteToShort(x: Byte): Short
are ambiguous when we try to convert from Byte to Int.
We fix that by adding a "tie-break" to implicit search
where if several methods match a numeric value result type
and all have numeric value types as result types, we
pick the numerically largest type that matches.
|
| |
|
|
|
|
| |
Mentioned in scala-user by Haoyi Li on 12-Mar-2014
|
|
|
|
|
|
| |
Now this is required only for members of a template. Local statements can still have implicits with no result type. (Maybe we need to get back on this).
Also, changed Dotty itself and tests to adhere to the new restriction.
|
|
|
|
|
|
| |
That is, in a selection qual.name(args), qual can be adapted to obtain a member "name" that matches args. Important to make usage patterns like this one work:
1 + BigInt(x)
|
|
|
|
| |
Plus a few bugfixes for implicits
|
|
|
|
| |
Also updated tests.
|
| |
|
|
|
|
| |
Plus a new test file: implicits1
|
|
|