mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 15:53:19 +00:00
Load special java methods as properites
Currently only those that override special builtin properties (e.g. `Collection.size`) Their modality is defined by method's modality
This commit is contained in:
@@ -13,6 +13,8 @@ public interface HalfSubstitutedTypeParameters {
|
||||
}
|
||||
|
||||
public interface TrickyList</*0*/ X, /*1*/ E> : kotlin.MutableList<E> {
|
||||
public abstract override /*1*/ /*fake_override*/ val size: kotlin.Int
|
||||
public abstract override /*1*/ /*fake_override*/ fun <get-size>(): kotlin.Int
|
||||
public abstract override /*1*/ /*fake_override*/ fun add(/*0*/ e: E): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun add(/*0*/ index: kotlin.Int, /*1*/ element: E): kotlin.Unit
|
||||
public abstract override /*1*/ /*fake_override*/ fun addAll(/*0*/ c: kotlin.Collection<E>): kotlin.Boolean
|
||||
@@ -32,7 +34,6 @@ public interface HalfSubstitutedTypeParameters {
|
||||
public abstract override /*1*/ /*fake_override*/ fun removeAll(/*0*/ c: kotlin.Collection<kotlin.Any?>): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun retainAll(/*0*/ c: kotlin.Collection<kotlin.Any?>): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun set(/*0*/ index: kotlin.Int, /*1*/ element: E): E
|
||||
public abstract override /*1*/ /*fake_override*/ fun size(): kotlin.Int
|
||||
public abstract override /*1*/ /*fake_override*/ fun subList(/*0*/ fromIndex: kotlin.Int, /*1*/ toIndex: kotlin.Int): kotlin.MutableList<E>
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
package test
|
||||
|
||||
public interface SubclassOfCollection</*0*/ E> : kotlin.MutableCollection<E> {
|
||||
public abstract override /*1*/ /*fake_override*/ val size: kotlin.Int
|
||||
public abstract override /*1*/ /*fake_override*/ fun <get-size>(): kotlin.Int
|
||||
public abstract override /*1*/ /*fake_override*/ fun add(/*0*/ e: E): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun addAll(/*0*/ c: kotlin.Collection<E>): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun clear(): kotlin.Unit
|
||||
@@ -11,5 +13,4 @@ public interface SubclassOfCollection</*0*/ E> : kotlin.MutableCollection<E> {
|
||||
public abstract override /*1*/ /*fake_override*/ fun remove(/*0*/ o: kotlin.Any?): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun removeAll(/*0*/ c: kotlin.Collection<kotlin.Any?>): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun retainAll(/*0*/ c: kotlin.Collection<kotlin.Any?>): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun size(): kotlin.Int
|
||||
}
|
||||
|
||||
@@ -8,5 +8,5 @@ public open class ModalityOfFakeOverrides : AbstractList<String>() {
|
||||
return ""
|
||||
}
|
||||
|
||||
override fun size(): Int = 0
|
||||
override val size: Int get() = 0
|
||||
}
|
||||
|
||||
@@ -3,6 +3,8 @@ package test
|
||||
public open class ModalityOfFakeOverrides : java.util.AbstractList<kotlin.String> {
|
||||
/*primary*/ public constructor ModalityOfFakeOverrides()
|
||||
protected/*protected and package*/ final override /*1*/ /*fake_override*/ var modCount: kotlin.Int
|
||||
public open override /*1*/ val size: kotlin.Int
|
||||
public open override /*1*/ fun <get-size>(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun add(/*0*/ index: kotlin.Int, /*1*/ element: kotlin.String!): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun add(/*0*/ e: kotlin.String!): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun addAll(/*0*/ c: kotlin.Collection<kotlin.String!>): kotlin.Boolean
|
||||
@@ -25,7 +27,6 @@ public open class ModalityOfFakeOverrides : java.util.AbstractList<kotlin.String
|
||||
protected/*protected and package*/ open override /*1*/ /*fake_override*/ fun removeRange(/*0*/ p0: kotlin.Int, /*1*/ p1: kotlin.Int): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun retainAll(/*0*/ c: kotlin.Collection<kotlin.Any?>): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun set(/*0*/ index: kotlin.Int, /*1*/ element: kotlin.String!): kotlin.String!
|
||||
public open override /*1*/ fun size(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun subList(/*0*/ fromIndex: kotlin.Int, /*1*/ toIndex: kotlin.Int): kotlin.MutableList<kotlin.String!>
|
||||
public open override /*1*/ /*fake_override*/ fun toArray(): kotlin.Array<(out) kotlin.Any!>!
|
||||
public open override /*1*/ /*fake_override*/ fun </*0*/ T : kotlin.Any!> toArray(/*0*/ p0: kotlin.Array<(out) T!>!): kotlin.Array<(out) T!>!
|
||||
|
||||
Reference in New Issue
Block a user