[FE] Add tests for 'containingClassForStaticMemberAttr'
This commit is contained in:
+7
@@ -0,0 +1,7 @@
|
||||
open class Foo<T>(val item: T)
|
||||
|
||||
class Bar(str: String) : Foo<String>(str)
|
||||
|
||||
fun usage(bar: Bar) {
|
||||
<!DEBUG_INFO_CALLABLE_OWNER("Bar.Bar in Bar")!>Bar("bar")<!>
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
open class Foo<T>(val item: T)
|
||||
|
||||
class Bar(str: String) : Foo<String>(str)
|
||||
|
||||
fun usage(bar: Bar) {
|
||||
<!DEBUG_INFO_CALLABLE_OWNER("Bar.<init> in Bar")!>Bar("bar")<!>
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
package
|
||||
|
||||
public fun usage(/*0*/ bar: Bar): kotlin.Unit
|
||||
|
||||
public final class Bar : Foo<kotlin.String> {
|
||||
public constructor Bar(/*0*/ str: kotlin.String)
|
||||
public final override /*1*/ /*fake_override*/ val item: kotlin.String
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public open class Foo</*0*/ T> {
|
||||
public constructor Foo</*0*/ T>(/*0*/ item: T)
|
||||
public final val item: T
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
open class Foo<T>(val item: T)
|
||||
|
||||
class Bar(str: String) : <!DEBUG_INFO_CALLABLE_OWNER("Foo.Foo in Bar")!>Foo<String>(str)<!>
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
open class Foo<T>(val item: T)
|
||||
|
||||
class Bar(str: String) : <!DEBUG_INFO_CALLABLE_OWNER("Foo.<init> in Foo")!>Foo<String>(str)<!>
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
package
|
||||
|
||||
public final class Bar : Foo<kotlin.String> {
|
||||
public constructor Bar(/*0*/ str: kotlin.String)
|
||||
public final override /*1*/ /*fake_override*/ val item: kotlin.String
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public open class Foo</*0*/ T> {
|
||||
public constructor Foo</*0*/ T>(/*0*/ item: T)
|
||||
public final val item: T
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
enum class Direction {
|
||||
NORTH, EAST, SOUTH, WEST
|
||||
}
|
||||
|
||||
fun usage() {
|
||||
<!DEBUG_INFO_CALLABLE_OWNER("Direction.values in Direction")!>Direction.values()<!>
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
enum class Direction {
|
||||
NORTH, EAST, SOUTH, WEST
|
||||
}
|
||||
|
||||
fun usage() {
|
||||
Direction.<!DEBUG_INFO_CALLABLE_OWNER("Direction.values in Direction")!>values()<!>
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package
|
||||
|
||||
public fun usage(): kotlin.Unit
|
||||
|
||||
public final enum class Direction : kotlin.Enum<Direction> {
|
||||
enum entry NORTH
|
||||
|
||||
enum entry EAST
|
||||
|
||||
enum entry SOUTH
|
||||
|
||||
enum entry WEST
|
||||
|
||||
private constructor Direction()
|
||||
@kotlin.internal.IntrinsicConstEvaluation public final override /*1*/ /*fake_override*/ val name: kotlin.String
|
||||
public final override /*1*/ /*fake_override*/ val ordinal: kotlin.Int
|
||||
protected final override /*1*/ /*fake_override*/ fun clone(): kotlin.Any
|
||||
public final override /*1*/ /*fake_override*/ fun compareTo(/*0*/ other: Direction): kotlin.Int
|
||||
public final override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
protected/*protected and package*/ final override /*1*/ /*fake_override*/ /*isHiddenForResolutionEverywhereBesideSupercalls*/ fun finalize(): kotlin.Unit
|
||||
public final override /*1*/ /*fake_override*/ /*isHiddenForResolutionEverywhereBesideSupercalls*/ fun getDeclaringClass(): java.lang.Class<Direction!>!
|
||||
public final override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
|
||||
// Static members
|
||||
public final /*synthesized*/ fun valueOf(/*0*/ value: kotlin.String): Direction
|
||||
public final /*synthesized*/ fun values(): kotlin.Array<Direction>
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
interface Foo<T> {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
interface Bar : Foo<String>
|
||||
|
||||
fun usage(bar: Bar) {
|
||||
<!DEBUG_INFO_CALLABLE_OWNER("Bar.foo in implicit Bar")!>bar.foo()<!>
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
interface Foo<T> {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
interface Bar : Foo<String>
|
||||
|
||||
fun usage(bar: Bar) {
|
||||
bar.<!DEBUG_INFO_CALLABLE_OWNER("Bar.foo in Bar")!>foo()<!>
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
package
|
||||
|
||||
public fun usage(/*0*/ bar: Bar): kotlin.Unit
|
||||
|
||||
public interface Bar : Foo<kotlin.String> {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface Foo</*0*/ T> {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
// MODULE: lib
|
||||
// FILE: test/J.java
|
||||
package test;
|
||||
|
||||
interface I {
|
||||
// Not a String to avoid constant inlining
|
||||
public static String[] OK = new String[]{"OK"};
|
||||
}
|
||||
|
||||
public class J implements I {}
|
||||
|
||||
// MODULE: main(lib)
|
||||
// FILE: k.kt
|
||||
import test.J
|
||||
|
||||
fun test() {
|
||||
<!DEBUG_INFO_CALLABLE_OWNER("test.I.OK in test.I")!>J.OK<!>
|
||||
}
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
// MODULE: lib
|
||||
// FILE: test/J.java
|
||||
package test;
|
||||
|
||||
interface I {
|
||||
// Not a String to avoid constant inlining
|
||||
public static String[] OK = new String[]{"OK"};
|
||||
}
|
||||
|
||||
public class J implements I {}
|
||||
|
||||
// MODULE: main(lib)
|
||||
// FILE: k.kt
|
||||
import test.J
|
||||
|
||||
fun test() {
|
||||
J.<!DEBUG_INFO_CALLABLE_OWNER("test.J.OK in test.J")!>OK<!>
|
||||
}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
// -- Module: <lib> --
|
||||
package
|
||||
|
||||
package test {
|
||||
|
||||
public/*package*/ interface I {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
|
||||
// Static members
|
||||
public final val OK: kotlin.Array<(out) kotlin.String!>!
|
||||
}
|
||||
|
||||
public open class J : test.I {
|
||||
public constructor J()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
|
||||
// Static members
|
||||
public final override /*1*/ /*fake_override*/ val OK: kotlin.Array<(out) kotlin.String!>!
|
||||
}
|
||||
}
|
||||
|
||||
// -- Module: <main> --
|
||||
package
|
||||
|
||||
public fun test(): kotlin.Unit
|
||||
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
// MODULE: lib
|
||||
// FILE: test/J.java
|
||||
package test;
|
||||
|
||||
class Foo<T> {
|
||||
public static <K> String getValue(K key) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public class Bar extends Foo<String> {}
|
||||
|
||||
// MODULE: main(lib)
|
||||
// FILE: k.kt
|
||||
import test.Bar
|
||||
|
||||
fun test() {
|
||||
<!DEBUG_INFO_CALLABLE_OWNER("test.Foo.getValue in test.Foo")!>Bar.getValue("bar")<!>
|
||||
}
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
// MODULE: lib
|
||||
// FILE: test/J.java
|
||||
package test;
|
||||
|
||||
class Foo<T> {
|
||||
public static <K> String getValue(K key) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public class Bar extends Foo<String> {}
|
||||
|
||||
// MODULE: main(lib)
|
||||
// FILE: k.kt
|
||||
import test.Bar
|
||||
|
||||
fun test() {
|
||||
Bar.<!DEBUG_INFO_CALLABLE_OWNER("test.Bar.getValue in test.Bar")!>getValue("bar")<!>
|
||||
}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
// -- Module: <lib> --
|
||||
package
|
||||
|
||||
package test {
|
||||
|
||||
public open class Bar : test.Foo<kotlin.String!> {
|
||||
public constructor Bar()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
|
||||
// Static members
|
||||
public open override /*1*/ /*fake_override*/ fun </*0*/ K : kotlin.Any!> getValue(/*0*/ key: K!): kotlin.String!
|
||||
}
|
||||
|
||||
public/*package*/ open class Foo</*0*/ T : kotlin.Any!> {
|
||||
public/*package*/ constructor Foo</*0*/ T : kotlin.Any!>()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
|
||||
// Static members
|
||||
public open fun </*0*/ K : kotlin.Any!> getValue(/*0*/ key: K!): kotlin.String!
|
||||
}
|
||||
}
|
||||
|
||||
// -- Module: <main> --
|
||||
package
|
||||
|
||||
public fun test(): kotlin.Unit
|
||||
Reference in New Issue
Block a user