Move: Do not update Kotlin usages of extension members, add imports instead

#KT-5378 Fixed
This commit is contained in:
Alexey Sedunov
2014-07-10 21:11:28 +04:00
parent 99ecb82ce0
commit 17dd5b9d05
112 changed files with 1061 additions and 5 deletions
@@ -0,0 +1,7 @@
package a
import b.test
fun bar() {
Test().test()
}
@@ -0,0 +1,8 @@
package a
import b.test as _test
import a.Test as _Test
fun bar() {
_Test()._test()
}
@@ -0,0 +1,7 @@
package a
open class Foo {
open class Bar {
}
}
@@ -0,0 +1,9 @@
package a
import b.test
class Test {
fun foo() {
test()
}
}
@@ -0,0 +1,7 @@
package a;
class J {
void bar() {
b.BPackage.test(new Test());
}
}
@@ -0,0 +1,7 @@
package a
import b.test
fun bar() {
Test().test()
}
@@ -0,0 +1,7 @@
package a;
class J {
void bar() {
b.BPackage.test(new Test());
}
}
@@ -0,0 +1,8 @@
package a
import b.test as _test
import a.Test as _Test
fun bar() {
_Test()._test()
}
@@ -0,0 +1,9 @@
package a;
import static b.BPackage.test;
class J {
void bar() {
test(new Test());
}
}
@@ -0,0 +1,30 @@
package b
import a.Test
open class Foo {
open class Bar {
}
}
fun Test.test() {
val aFoo: a.Foo = a.Foo()
val bFoo: Foo = Foo()
val cFoo: c.Foo = c.Foo()
val aBar: a.Foo.Bar = a.Foo.Bar()
val bBar: Foo.Bar = Foo.Bar()
val cBar: c.Foo.Bar = c.Foo.Bar()
fun foo(u: Int) {
class T(val t: Int)
object O {
val t: Int = 1
}
val v = T(u).t + O.t
println(v)
}
foo(1)
}
@@ -0,0 +1,7 @@
package b;
class J {
void bar() {
b.BPackage.test(new a.Test());
}
}
@@ -0,0 +1,9 @@
package b;
import a.*;
class J {
void bar() {
b.BPackage.test(new Test());
}
}
@@ -0,0 +1,7 @@
package b
import a.*
fun bar() {
Test().test()
}
@@ -0,0 +1,7 @@
package b;
class J {
void bar() {
b.BPackage.test(new a.Test());
}
}
@@ -0,0 +1,9 @@
package b;
import a.Test;
class J {
void bar() {
b.BPackage.test(new Test());
}
}
@@ -0,0 +1,8 @@
package b
import b.test
import a.Test
fun bar() {
Test().test()
}
@@ -0,0 +1,8 @@
package b
import b.test as _test
import a.Test as _Test
fun bar() {
_Test()._test()
}
@@ -0,0 +1,9 @@
package b;
import static b.BPackage.test;
class J {
void bar() {
test(new a.Test());
}
}
@@ -0,0 +1,7 @@
package c
open class Foo {
open class Bar {
}
}
@@ -0,0 +1,7 @@
package c;
class J {
void bar() {
b.BPackage.test(new a.Test());
}
}
@@ -0,0 +1,9 @@
package c;
import a.*;
class J {
void bar() {
b.BPackage.test(new Test());
}
}
@@ -0,0 +1,8 @@
package c
import a.*
import b.test
fun bar() {
Test().test()
}
@@ -0,0 +1,7 @@
package c;
class J {
void bar() {
b.BPackage.test(new a.Test());
}
}
@@ -0,0 +1,9 @@
package c;
import a.Test;
class J {
void bar() {
b.BPackage.test(new Test());
}
}
@@ -0,0 +1,8 @@
package c
import b.test
import a.Test
fun bar() {
Test().test()
}
@@ -0,0 +1,8 @@
package c
import b.test as _test
import a.Test as _Test
fun bar() {
_Test()._test()
}
@@ -0,0 +1,9 @@
package c;
import static b.BPackage.test;
class J {
void bar() {
test(new a.Test());
}
}
@@ -0,0 +1,5 @@
package a
fun bar() {
Test().test()
}
@@ -0,0 +1,8 @@
package a
import a.test as _test
import a.Test as _Test
fun bar() {
_Test()._test()
}
@@ -0,0 +1,7 @@
package a
open class Foo {
open class Bar {
}
}
@@ -0,0 +1,28 @@
package a
fun Test.<caret>test() {
val aFoo: Foo = Foo()
val bFoo: b.Foo = b.Foo()
val cFoo: c.Foo = c.Foo()
val aBar: Foo.Bar = Foo.Bar()
val bBar: b.Foo.Bar = b.Foo.Bar()
val cBar: c.Foo.Bar = c.Foo.Bar()
fun foo(u: Int) {
class T(val t: Int)
object O {
val t: Int = 1
}
val v = T(u).t + O.t
println(v)
}
foo(1)
}
class Test {
fun foo() {
test()
}
}
@@ -0,0 +1,7 @@
package a;
class J {
void bar() {
APackage.test(new Test());
}
}
@@ -0,0 +1,5 @@
package a
fun bar() {
Test().test()
}
@@ -0,0 +1,9 @@
package a;
import static a.APackage.*;
class J {
void bar() {
test(new Test());
}
}
@@ -0,0 +1,8 @@
package a
import a.test as _test
import a.Test as _Test
fun bar() {
_Test()._test()
}
@@ -0,0 +1,9 @@
package a;
import static a.APackage.test;
class J {
void bar() {
test(new Test());
}
}
@@ -0,0 +1,8 @@
package b
open class Foo {
open class Bar {
}
}
@@ -0,0 +1,7 @@
package b;
class J {
void bar() {
a.APackage.test(new a.Test());
}
}
@@ -0,0 +1,9 @@
package b;
import a.*;
class J {
void bar() {
APackage.test(new Test());
}
}
@@ -0,0 +1,7 @@
package b
import a.*
fun bar() {
Test().test()
}
@@ -0,0 +1,9 @@
package b;
import static a.APackage.*;
class J {
void bar() {
test(new a.Test());
}
}
@@ -0,0 +1,10 @@
package b;
import a.APackage;
import a.Test;
class J {
void bar() {
APackage.test(new Test());
}
}
@@ -0,0 +1,8 @@
package b
import a.test
import a.Test
fun bar() {
Test().test()
}
@@ -0,0 +1,8 @@
package b
import a.test as _test
import a.Test as _Test
fun bar() {
_Test()._test()
}
@@ -0,0 +1,9 @@
package b;
import static a.APackage.test;
class J {
void bar() {
test(new a.Test());
}
}
@@ -0,0 +1,7 @@
package c
open class Foo {
open class Bar {
}
}
@@ -0,0 +1,7 @@
package c;
class J {
void bar() {
a.APackage.test(new a.Test());
}
}
@@ -0,0 +1,9 @@
package c;
import a.*;
class J {
void bar() {
APackage.test(new Test());
}
}
@@ -0,0 +1,7 @@
package c
import a.*
fun bar() {
Test().test()
}
@@ -0,0 +1,9 @@
package c;
import static a.APackage.*;
class J {
void bar() {
test(new a.Test());
}
}
@@ -0,0 +1,10 @@
package c;
import a.APackage;
import a.Test;
class J {
void bar() {
APackage.test(new Test());
}
}
@@ -0,0 +1,8 @@
package c
import a.test
import a.Test
fun bar() {
Test().test()
}
@@ -0,0 +1,8 @@
package c
import a.test as _test
import a.Test as _Test
fun bar() {
_Test()._test()
}
@@ -0,0 +1,9 @@
package c;
import static a.APackage.test;
class J {
void bar() {
test(new a.Test());
}
}
@@ -0,0 +1,5 @@
{
"mainFile": "a/main.kt",
"type": "MOVE_KOTLIN_TOP_LEVEL_DECLARATIONS",
"targetFile": "b/dependency.kt"
}