Switch kotlin version to 1.8
with appropriate fixes in testdata, tests and other places.
This commit is contained in:
@@ -22,10 +22,10 @@ fun <T> takes(range: T) {}
|
||||
fun <T> takes(range: T) where T : Collection<*>, T: ClosedRange<*> {}
|
||||
|
||||
fun main() {
|
||||
SmartList(<!PROGRESSIONS_CHANGING_RESOLVE_WARNING("fun <E> SmartList(x: Collection<E>): Unit")!>1..2<!>) // warning
|
||||
SmartList(<!PROGRESSIONS_CHANGING_RESOLVE_ERROR!>1..2<!>) // warning
|
||||
SmartList<IntRange>(1..10) // no warning
|
||||
|
||||
append(<!PROGRESSIONS_CHANGING_RESOLVE_WARNING("fun append(x: Collection<*>): Unit")!>1..10<!>) // warning
|
||||
append(<!PROGRESSIONS_CHANGING_RESOLVE_ERROR!>1..10<!>) // warning
|
||||
append((1..10) as Any) // no warning
|
||||
append((1..10) as Iterable<Int>) // no warning
|
||||
append("a".."z") // no warning, the range is not iterable
|
||||
@@ -35,9 +35,9 @@ fun main() {
|
||||
|
||||
append3(In(1..10)) // no warning
|
||||
|
||||
append4(<!PROGRESSIONS_CHANGING_RESOLVE_WARNING("fun <E : Collection<*>> append4(x: E): Unit")!>1..10<!>) // warning
|
||||
append4(<!PROGRESSIONS_CHANGING_RESOLVE_ERROR!>1..10<!>) // warning
|
||||
|
||||
append4<IntRange>(1..10) // warning
|
||||
|
||||
takes(<!PROGRESSIONS_CHANGING_RESOLVE_WARNING("fun <T : Collection<*>> takes(range: T): Unit where T : ClosedRange<*>")!>1..10<!>) // warning
|
||||
takes(<!PROGRESSIONS_CHANGING_RESOLVE_ERROR!>1..10<!>) // warning
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user