-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Backport "Improve parameter type inference error messaging" to LTS (#…
- Loading branch information
Showing
5 changed files
with
32 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,16 @@ | ||
-- [E081] Type Error: tests/neg/i11350.scala:1:39 ---------------------------------------------------------------------- | ||
1 |class A1[T](action: A1[T] ?=> String = "") // error | ||
| ^ | ||
| Missing parameter type | ||
| Could not infer type for parameter evidence$1 of anonymous function | ||
| | ||
| I could not infer the type of the parameter evidence$1. | ||
| What I could infer was: A1[<?>] | ||
| Partially inferred type for the parameter: A1[<?>] | ||
| | ||
| Expected type for the whole anonymous function: (A1[<?>]) ?=> String | ||
-- [E081] Type Error: tests/neg/i11350.scala:2:39 ---------------------------------------------------------------------- | ||
2 |class A2[T](action: A1[T] ?=> String = summon[A1[T]]) // error | ||
| ^ | ||
| Missing parameter type | ||
| Could not infer type for parameter evidence$2 of anonymous function | ||
| | ||
| Partially inferred type for the parameter: A1[<?>] | ||
| | ||
| I could not infer the type of the parameter evidence$2. | ||
| What I could infer was: A1[<?>] | ||
| Expected type for the whole anonymous function: (A1[<?>]) ?=> String |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters