Fix compiler tests
This commit is contained in:
+1
-1
@@ -5,7 +5,7 @@ public fun list(/*0*/ start: SomeObject): kotlin.Unit
|
||||
@kotlin.data() public final class SomeObject {
|
||||
public constructor SomeObject(/*0*/ n: SomeObject?)
|
||||
public final val n: SomeObject?
|
||||
public final /*synthesized*/ fun component1(): SomeObject?
|
||||
public final operator /*synthesized*/ fun component1(): SomeObject?
|
||||
public final /*synthesized*/ fun copy(/*0*/ n: SomeObject? = ...): SomeObject
|
||||
public final fun doSomething(): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
|
||||
@@ -5,7 +5,7 @@ public fun list(/*0*/ start: SomeObject): SomeObject
|
||||
@kotlin.data() public final class SomeObject {
|
||||
public constructor SomeObject(/*0*/ n: SomeObject?)
|
||||
public final val n: SomeObject?
|
||||
public final /*synthesized*/ fun component1(): SomeObject?
|
||||
public final operator /*synthesized*/ fun component1(): SomeObject?
|
||||
public final /*synthesized*/ fun copy(/*0*/ n: SomeObject? = ...): SomeObject
|
||||
public final fun doSomething(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@ public fun list(/*0*/ start: SomeObject): SomeObject
|
||||
@kotlin.data() public final class SomeObject {
|
||||
public constructor SomeObject(/*0*/ n: SomeObject?)
|
||||
public final val n: SomeObject?
|
||||
public final /*synthesized*/ fun component1(): SomeObject?
|
||||
public final operator /*synthesized*/ fun component1(): SomeObject?
|
||||
public final /*synthesized*/ fun copy(/*0*/ n: SomeObject? = ...): SomeObject
|
||||
public final fun doSomething(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@ public fun list(/*0*/ start: SomeObject): SomeObject
|
||||
@kotlin.data() public final class SomeObject {
|
||||
public constructor SomeObject(/*0*/ n: SomeObject?)
|
||||
public final val n: SomeObject?
|
||||
public final /*synthesized*/ fun component1(): SomeObject?
|
||||
public final operator /*synthesized*/ fun component1(): SomeObject?
|
||||
public final /*synthesized*/ fun copy(/*0*/ n: SomeObject? = ...): SomeObject
|
||||
public final fun doSomething(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@ public fun list(/*0*/ start: SomeObject): kotlin.Unit
|
||||
@kotlin.data() public final class SomeObject {
|
||||
public constructor SomeObject(/*0*/ n: SomeObject?)
|
||||
public final val n: SomeObject?
|
||||
public final /*synthesized*/ fun component1(): SomeObject?
|
||||
public final operator /*synthesized*/ fun component1(): SomeObject?
|
||||
public final /*synthesized*/ fun copy(/*0*/ n: SomeObject? = ...): SomeObject
|
||||
public final fun doSomething(): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
|
||||
@@ -5,7 +5,7 @@ public fun list(/*0*/ start: SomeObject): kotlin.Unit
|
||||
@kotlin.data() public final class SomeObject {
|
||||
public constructor SomeObject(/*0*/ n: SomeObject?)
|
||||
public final val n: SomeObject?
|
||||
public final /*synthesized*/ fun component1(): SomeObject?
|
||||
public final operator /*synthesized*/ fun component1(): SomeObject?
|
||||
public final /*synthesized*/ fun copy(/*0*/ n: SomeObject? = ...): SomeObject
|
||||
public final fun doSomething(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
class MyClass
|
||||
|
||||
// In principle it is not correct, MyClass? is not a subtype of MyClass
|
||||
fun MyClass.inc(): MyClass? { return null }
|
||||
operator fun MyClass.inc(): MyClass? { return null }
|
||||
|
||||
public fun box() : MyClass? {
|
||||
var i : MyClass?
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
package
|
||||
|
||||
public fun box(): MyClass?
|
||||
public fun MyClass.inc(): MyClass?
|
||||
public operator fun MyClass.inc(): MyClass?
|
||||
|
||||
public final class MyClass {
|
||||
public constructor MyClass()
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
class MyClass
|
||||
|
||||
// Correct at compile time but wrong at run-time
|
||||
fun MyClass?.inc(): MyClass? { return null }
|
||||
operator fun MyClass?.inc(): MyClass? { return null }
|
||||
|
||||
public fun box() : MyClass? {
|
||||
var i : MyClass?
|
||||
|
||||
Vendored
+1
-1
@@ -1,7 +1,7 @@
|
||||
package
|
||||
|
||||
public fun box(): MyClass?
|
||||
public fun MyClass?.inc(): MyClass?
|
||||
public operator fun MyClass?.inc(): MyClass?
|
||||
|
||||
public final class MyClass {
|
||||
public constructor MyClass()
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
fun Int?.inc(): Int? { return this }
|
||||
operator fun Int?.inc(): Int? { return this }
|
||||
|
||||
public fun box(arg: Int?) : Int? {
|
||||
var i : Int? = arg
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package
|
||||
|
||||
public fun box(/*0*/ arg: kotlin.Int?): kotlin.Int?
|
||||
public fun kotlin.Int?.inc(): kotlin.Int?
|
||||
public operator fun kotlin.Int?.inc(): kotlin.Int?
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
class MyClass
|
||||
|
||||
// In principle it is not correct, MyClass? is not a subtype of MyClass
|
||||
fun MyClass.inc(): MyClass? { return null }
|
||||
operator fun MyClass.inc(): MyClass? { return null }
|
||||
|
||||
public fun box() {
|
||||
var i : MyClass?
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
package
|
||||
|
||||
public fun box(): kotlin.Unit
|
||||
public fun MyClass.inc(): MyClass?
|
||||
public operator fun MyClass.inc(): MyClass?
|
||||
|
||||
public final class MyClass {
|
||||
public constructor MyClass()
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
class MyClass
|
||||
|
||||
// Correct at compile time but wrong at run-time
|
||||
fun MyClass?.inc(): MyClass? { return null }
|
||||
operator fun MyClass?.inc(): MyClass? { return null }
|
||||
|
||||
public fun box() {
|
||||
var i : MyClass?
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
package
|
||||
|
||||
public fun box(): kotlin.Unit
|
||||
public fun MyClass?.inc(): MyClass?
|
||||
public operator fun MyClass?.inc(): MyClass?
|
||||
|
||||
public final class MyClass {
|
||||
public constructor MyClass()
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
fun Int?.inc(): Int? { return this }
|
||||
operator fun Int?.inc(): Int? { return this }
|
||||
|
||||
public fun box(arg: Int?) : Int? {
|
||||
var i = arg
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package
|
||||
|
||||
public fun box(/*0*/ arg: kotlin.Int?): kotlin.Int?
|
||||
public fun kotlin.Int?.inc(): kotlin.Int?
|
||||
public operator fun kotlin.Int?.inc(): kotlin.Int?
|
||||
|
||||
+3
-3
@@ -1,10 +1,10 @@
|
||||
fun create(): Map<String, String> = null!!
|
||||
|
||||
fun <K, V> Map<K, V>.iterator(): Iterator<Map.Entry<K, V>> = null!!
|
||||
operator fun <K, V> Map<K, V>.iterator(): Iterator<Map.Entry<K, V>> = null!!
|
||||
|
||||
fun <K, V> Map.Entry<K, V>.component1() = getKey()
|
||||
operator fun <K, V> Map.Entry<K, V>.component1() = getKey()
|
||||
|
||||
fun <K, V> Map.Entry<K, V>.component2() = getValue()
|
||||
operator fun <K, V> Map.Entry<K, V>.component2() = getValue()
|
||||
|
||||
class MyClass {
|
||||
private var m: Map<String, String>? = null
|
||||
|
||||
+3
-3
@@ -1,9 +1,9 @@
|
||||
package
|
||||
|
||||
public fun create(): kotlin.Map<kotlin.String, kotlin.String>
|
||||
public fun </*0*/ K, /*1*/ V> kotlin.Map.Entry<K, V>.component1(): K
|
||||
public fun </*0*/ K, /*1*/ V> kotlin.Map.Entry<K, V>.component2(): V
|
||||
public fun </*0*/ K, /*1*/ V> kotlin.Map<K, V>.iterator(): kotlin.Iterator<kotlin.Map.Entry<K, V>>
|
||||
public operator fun </*0*/ K, /*1*/ V> kotlin.Map.Entry<K, V>.component1(): K
|
||||
public operator fun </*0*/ K, /*1*/ V> kotlin.Map.Entry<K, V>.component2(): V
|
||||
public operator fun </*0*/ K, /*1*/ V> kotlin.Map<K, V>.iterator(): kotlin.Iterator<kotlin.Map.Entry<K, V>>
|
||||
|
||||
public final class MyClass {
|
||||
public constructor MyClass()
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@ public fun list(/*0*/ start: SomeObject): kotlin.Unit
|
||||
@kotlin.data() public final class SomeObject {
|
||||
public constructor SomeObject(/*0*/ n: SomeObject?)
|
||||
public final val n: SomeObject?
|
||||
public final /*synthesized*/ fun component1(): SomeObject?
|
||||
public final operator /*synthesized*/ fun component1(): SomeObject?
|
||||
public final /*synthesized*/ fun copy(/*0*/ n: SomeObject? = ...): SomeObject
|
||||
public final fun doSomething(): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
|
||||
Reference in New Issue
Block a user