Converter:
Omit Unit return type Refactor handling of Unit type: extract separate object UnitType
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
package test
|
||||
public open class Test(str : String) {
|
||||
var myStr : String = "String2"
|
||||
public open fun sout(str : String) : Unit {
|
||||
public open fun sout(str : String) {
|
||||
System.out.println(str)
|
||||
}
|
||||
public open fun dummy(str : String) : String {
|
||||
return str
|
||||
}
|
||||
public open fun test() : Unit {
|
||||
public open fun test() {
|
||||
sout("String")
|
||||
val test = "String2"
|
||||
sout(test)
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
package test
|
||||
public open class Test(str : String) {
|
||||
var myStr : String = "String2"
|
||||
public open fun sout(str : String) : Unit {
|
||||
public open fun sout(str : String) {
|
||||
System.out?.println(str)
|
||||
}
|
||||
public open fun dummy(str : String) : String {
|
||||
return str
|
||||
}
|
||||
public open fun test() : Unit {
|
||||
public open fun test() {
|
||||
sout("String")
|
||||
var test : String = "String2"
|
||||
sout(test)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package test
|
||||
open class Foo() {
|
||||
open fun execute() : Unit {
|
||||
open fun execute() {
|
||||
}
|
||||
}
|
||||
open class Bar() {
|
||||
@@ -8,7 +8,7 @@ var fooNotNull : Foo = Foo()
|
||||
var fooNullable : Foo = null
|
||||
}
|
||||
open class Test() {
|
||||
public open fun test(barNotNull : Bar, barNullable : Bar) : Unit {
|
||||
public open fun test(barNotNull : Bar, barNullable : Bar) {
|
||||
barNotNull.fooNotNull.execute()
|
||||
barNotNull.fooNullable.execute()
|
||||
barNullable.fooNotNull.execute()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package test
|
||||
open class Foo() {
|
||||
open fun execute() : Unit {
|
||||
open fun execute() {
|
||||
}
|
||||
}
|
||||
open class Bar() {
|
||||
@@ -8,7 +8,7 @@ var fooNotNull : Foo = Foo()
|
||||
var fooNullable : Foo? = null
|
||||
}
|
||||
open class Test() {
|
||||
public open fun test(barNotNull : Bar, barNullable : Bar?) : Unit {
|
||||
public open fun test(barNotNull : Bar, barNullable : Bar?) {
|
||||
barNotNull.fooNotNull.execute()
|
||||
barNotNull.fooNullable?.execute()
|
||||
barNullable?.fooNotNull?.execute()
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
fun fromArrayToCollection(a : Array<Foo>) : Unit {
|
||||
fun fromArrayToCollection(a : Array<Foo>) {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun fromArrayToCollection(a : Array<Foo?>?) : Unit {
|
||||
fun fromArrayToCollection(a : Array<Foo?>?) {
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
import java.util.BitSet
|
||||
open class Foo() {
|
||||
open fun foo(o : BitSet) : Unit {
|
||||
open fun foo(o : BitSet) {
|
||||
val o2 = o
|
||||
val foo = 0
|
||||
foo = o2.size()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import java.util.BitSet
|
||||
open class Foo() {
|
||||
open fun foo(o : BitSet?) : Unit {
|
||||
open fun foo(o : BitSet?) {
|
||||
var o2 : BitSet? = o
|
||||
var foo : Int = 0
|
||||
foo = o2?.size()!!
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import java.util.ArrayList
|
||||
open class Boxing() {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val i = 0
|
||||
val n = 0.0.toFloat()
|
||||
i = 1
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import java.util.ArrayList
|
||||
open class Boxing() {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var i : Int? = 0
|
||||
var n : Number? = 0.0.toFloat()
|
||||
i = 1
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val i = Integer.valueOf(100)
|
||||
val s = 3
|
||||
val ss = java.lang.Short.valueOf(s)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var i : Int? = Integer.valueOf(100)
|
||||
var s : Short = 3
|
||||
var ss : Short? = java.lang.Short.valueOf(s)
|
||||
|
||||
@@ -4,7 +4,7 @@ val ourOut : java.io.PrintStream = 0
|
||||
}
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
Library.ourOut.print()
|
||||
}
|
||||
}
|
||||
@@ -4,7 +4,7 @@ val ourOut : java.io.PrintStream? = null
|
||||
}
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
Library.ourOut?.print()
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
open class Library() {
|
||||
class object {
|
||||
open fun call() : Unit {
|
||||
open fun call() {
|
||||
}
|
||||
open fun getString() : String {
|
||||
return ""
|
||||
@@ -8,7 +8,7 @@ return ""
|
||||
}
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
Library.call()
|
||||
Library.getString().isEmpty()
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
open class Library() {
|
||||
class object {
|
||||
open fun call() : Unit {
|
||||
open fun call() {
|
||||
}
|
||||
open fun getString() : String? {
|
||||
return ""
|
||||
@@ -8,7 +8,7 @@ return ""
|
||||
}
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
Library.call()
|
||||
Library.getString()?.isEmpty()
|
||||
}
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
open class Library() {
|
||||
open fun call() : Unit {
|
||||
open fun call() {
|
||||
}
|
||||
open fun getString() : String {
|
||||
return ""
|
||||
}
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
val lib = Library()
|
||||
lib.call()
|
||||
lib.getString().isEmpty()
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
open class Library() {
|
||||
open fun call() : Unit {
|
||||
open fun call() {
|
||||
}
|
||||
open fun getString() : String? {
|
||||
return ""
|
||||
}
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
var lib : Library? = Library()
|
||||
lib?.call()
|
||||
lib?.getString()?.isEmpty()
|
||||
|
||||
@@ -2,7 +2,7 @@ open class Library() {
|
||||
public val myString : String = 0
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
Library.myString.isEmpty()
|
||||
}
|
||||
}
|
||||
@@ -2,7 +2,7 @@ open class Library() {
|
||||
public val myString : String? = null
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
Library.myString?.isEmpty()
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,7 @@ return Short()
|
||||
}
|
||||
open class Test() {
|
||||
class object {
|
||||
public open fun test() : Unit {
|
||||
public open fun test() {
|
||||
test.Short.valueOf("1")
|
||||
test.Short.valueOf("1")
|
||||
java.lang.Short.valueOf("1")
|
||||
|
||||
@@ -8,7 +8,7 @@ return Short()
|
||||
}
|
||||
open class Test() {
|
||||
class object {
|
||||
public open fun test() : Unit {
|
||||
public open fun test() {
|
||||
test.Short.valueOf("1")
|
||||
test.Short.valueOf("1")
|
||||
java.lang.Short.valueOf("1")
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
abstract class A() {
|
||||
abstract fun callme() : Unit
|
||||
open fun callmetoo() : Unit {
|
||||
abstract fun callme()
|
||||
open fun callmetoo() {
|
||||
print("This is a concrete method.")
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
abstract class A() {
|
||||
abstract fun callme() : Unit
|
||||
open fun callmetoo() : Unit {
|
||||
abstract fun callme()
|
||||
open fun callmetoo() {
|
||||
print("This is a concrete method.")
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
abstract class Shape() {
|
||||
public var color : String = 0
|
||||
public open fun setColor(c : String) : Unit {
|
||||
public open fun setColor(c : String) {
|
||||
color = c
|
||||
}
|
||||
public open fun getColor() : String {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
abstract class Shape() {
|
||||
public var color : String? = null
|
||||
public open fun setColor(c : String?) : Unit {
|
||||
public open fun setColor(c : String?) {
|
||||
color = c
|
||||
}
|
||||
public open fun getColor() : String? {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
class T() {
|
||||
fun main() : Unit {
|
||||
fun main() {
|
||||
}
|
||||
fun i() : Int {
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
class T() {
|
||||
fun main() : Unit {
|
||||
fun main() {
|
||||
}
|
||||
fun i() : Int {
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@ return __
|
||||
}
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
val m = HashMap(1)
|
||||
val m2 = HashMap(10)
|
||||
val t1 = Test.init()
|
||||
|
||||
@@ -13,7 +13,7 @@ return __
|
||||
}
|
||||
}
|
||||
open class User() {
|
||||
open fun main() : Unit {
|
||||
open fun main() {
|
||||
var m : HashMap<Any?, Any?>? = HashMap(1)
|
||||
var m2 : HashMap<Any?, Any?>? = HashMap(10)
|
||||
var t1 : Test? = Test.init()
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
public open class MyClass() {
|
||||
private fun init(arg1 : Int, arg2 : Int, arg3 : Int) : Unit {
|
||||
private fun init(arg1 : Int, arg2 : Int, arg3 : Int) {
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
public open class MyClass() {
|
||||
private fun init(arg1 : Int, arg2 : Int, arg3 : Int) : Unit {
|
||||
private fun init(arg1 : Int, arg2 : Int, arg3 : Int) {
|
||||
}
|
||||
}
|
||||
@@ -12,7 +12,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
val c1 = C(100, 100, 100)
|
||||
val c2 = C.init(100, 100)
|
||||
val c3 = C.init(100)
|
||||
|
||||
@@ -12,7 +12,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
var c1 : C? = C(100, 100, 100)
|
||||
var c2 : C? = C.init(100, 100)
|
||||
var c3 : C? = C.init(100)
|
||||
|
||||
@@ -24,7 +24,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
val c1 = C.init(100, 100, 100)
|
||||
val c2 = C.init(100, 100)
|
||||
val c3 = C(100)
|
||||
|
||||
@@ -24,7 +24,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
var c1 : C? = C.init(100, 100, 100)
|
||||
var c2 : C? = C.init(100, 100)
|
||||
var c3 : C? = C(100)
|
||||
|
||||
@@ -8,9 +8,9 @@ return _firstName
|
||||
public open fun getLastName() : String {
|
||||
return _lastName
|
||||
}
|
||||
private fun doSmthBefore() : Unit {
|
||||
private fun doSmthBefore() {
|
||||
}
|
||||
private fun doSmthAfter() : Unit {
|
||||
private fun doSmthAfter() {
|
||||
}
|
||||
{
|
||||
doSmthBefore()
|
||||
@@ -36,7 +36,7 @@ return Customer(_firstName, _lastName)
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
val customer = CustomerBuilder().WithFirstName("Homer").WithLastName("Simpson").Build()
|
||||
System.out.println(customer.getFirstName())
|
||||
System.out.println(customer.getLastName())
|
||||
|
||||
@@ -8,9 +8,9 @@ return _firstName
|
||||
public open fun getLastName() : String? {
|
||||
return _lastName
|
||||
}
|
||||
private fun doSmthBefore() : Unit {
|
||||
private fun doSmthBefore() {
|
||||
}
|
||||
private fun doSmthAfter() : Unit {
|
||||
private fun doSmthAfter() {
|
||||
}
|
||||
{
|
||||
doSmthBefore()
|
||||
@@ -36,7 +36,7 @@ return Customer(_firstName, _lastName)
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
var customer : Customer? = CustomerBuilder().WithFirstName("Homer")?.WithLastName("Simpson")?.Build()
|
||||
System.out?.println(customer?.getFirstName())
|
||||
System.out?.println(customer?.getLastName())
|
||||
|
||||
@@ -28,7 +28,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
val i1 = Identifier.init<String>("name", false, true)
|
||||
val i2 = Identifier.init<String>("name", false)
|
||||
val i3 = Identifier.init<String>("name")
|
||||
|
||||
@@ -28,7 +28,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
var i1 : Identifier<*>? = Identifier.init<String?>("name", false, true)
|
||||
var i2 : Identifier<*>? = Identifier.init<String?>("name", false)
|
||||
var i3 : Identifier<*>? = Identifier.init<String?>("name")
|
||||
|
||||
@@ -28,7 +28,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
val i1 = Identifier.init("name", false, true)
|
||||
val i2 = Identifier.init("name", false)
|
||||
val i3 = Identifier.init("name")
|
||||
|
||||
@@ -28,7 +28,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
var i1 : Identifier? = Identifier.init("name", false, true)
|
||||
var i2 : Identifier? = Identifier.init("name", false)
|
||||
var i3 : Identifier? = Identifier.init("name")
|
||||
|
||||
@@ -33,7 +33,7 @@ return ""
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
val t = Test.init("name")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ return ""
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main() : Unit {
|
||||
public open fun main() {
|
||||
var t : Test? = Test.init("name")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
enum class E {
|
||||
FOO
|
||||
fun foo() : Unit {
|
||||
fun foo() {
|
||||
FOO.toString()
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
enum class E {
|
||||
FOO
|
||||
fun foo() : Unit {
|
||||
fun foo() {
|
||||
FOO.toString()
|
||||
}
|
||||
}
|
||||
@@ -4,7 +4,7 @@ BLACK
|
||||
RED
|
||||
YELLOW
|
||||
BLUE
|
||||
public override fun run() : Unit {
|
||||
public override fun run() {
|
||||
System.out.println("name()=" + name() + ", toString()=" + toString())
|
||||
}
|
||||
}
|
||||
@@ -4,7 +4,7 @@ BLACK
|
||||
RED
|
||||
YELLOW
|
||||
BLUE
|
||||
public override fun run() : Unit {
|
||||
public override fun run() {
|
||||
System.out?.println("name()=" + name() + ", toString()=" + toString())
|
||||
}
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun main() : Unit {
|
||||
fun main() {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun main() : Unit {
|
||||
fun main() {
|
||||
}
|
||||
@@ -12,7 +12,7 @@ return super.clone()
|
||||
public override fun toString() : String {
|
||||
return super.toString()
|
||||
}
|
||||
protected override fun finalize() : Unit {
|
||||
protected override fun finalize() {
|
||||
super.finalize()
|
||||
}
|
||||
}
|
||||
@@ -29,7 +29,7 @@ return super.clone()
|
||||
public open fun toString() : String {
|
||||
return getJavaClass<Base>.getName() + '@' + Integer.toHexString(hashCode())
|
||||
}
|
||||
protected open fun finalize() : Unit {
|
||||
protected open fun finalize() {
|
||||
super.finalize()
|
||||
}
|
||||
}
|
||||
@@ -12,7 +12,7 @@ return super.clone()
|
||||
public override fun toString() : String? {
|
||||
return super.toString()
|
||||
}
|
||||
protected override fun finalize() : Unit {
|
||||
protected override fun finalize() {
|
||||
super.finalize()
|
||||
}
|
||||
}
|
||||
@@ -29,7 +29,7 @@ return super.clone()
|
||||
public open fun toString() : String? {
|
||||
return getJavaClass<Base>.getName() + '@' + Integer.toHexString(hashCode())
|
||||
}
|
||||
protected open fun finalize() : Unit {
|
||||
protected open fun finalize() {
|
||||
super.finalize()
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
package demo
|
||||
class Final() {
|
||||
fun test() : Unit {
|
||||
fun test() {
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
package demo
|
||||
class Final() {
|
||||
fun test() : Unit {
|
||||
fun test() {
|
||||
}
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun test() : Unit {
|
||||
fun test() {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun test() : Unit {
|
||||
fun test() {
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
class object {
|
||||
public fun main(args : Array<String>) : Unit {
|
||||
public fun main(args : Array<String>) {
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
class object {
|
||||
public fun main(args : Array<String?>?) : Unit {
|
||||
public fun main(args : Array<String?>?) {
|
||||
}
|
||||
}
|
||||
@@ -1,8 +1,8 @@
|
||||
open class A() {
|
||||
open fun a() : Unit {
|
||||
open fun a() {
|
||||
}
|
||||
}
|
||||
class B() : A() {
|
||||
override fun a() : Unit {
|
||||
override fun a() {
|
||||
}
|
||||
}
|
||||
@@ -1,8 +1,8 @@
|
||||
open class A() {
|
||||
open fun a() : Unit {
|
||||
open fun a() {
|
||||
}
|
||||
}
|
||||
class B() : A() {
|
||||
override fun a() : Unit {
|
||||
override fun a() {
|
||||
}
|
||||
}
|
||||
@@ -1,12 +1,12 @@
|
||||
open class A() {
|
||||
open fun foo() : Unit {
|
||||
open fun foo() {
|
||||
}
|
||||
}
|
||||
open class B() : A() {
|
||||
override fun foo() : Unit {
|
||||
override fun foo() {
|
||||
}
|
||||
}
|
||||
open class C() : B() {
|
||||
override fun foo() : Unit {
|
||||
override fun foo() {
|
||||
}
|
||||
}
|
||||
@@ -1,12 +1,12 @@
|
||||
open class A() {
|
||||
open fun foo() : Unit {
|
||||
open fun foo() {
|
||||
}
|
||||
}
|
||||
open class B() : A() {
|
||||
override fun foo() : Unit {
|
||||
override fun foo() {
|
||||
}
|
||||
}
|
||||
open class C() : B() {
|
||||
override fun foo() : Unit {
|
||||
override fun foo() {
|
||||
}
|
||||
}
|
||||
@@ -12,7 +12,7 @@ return super.clone()
|
||||
public open fun toString() : String {
|
||||
return getJavaClass<Test>.getName() + '@' + Integer.toHexString(hashCode())
|
||||
}
|
||||
protected open fun finalize() : Unit {
|
||||
protected open fun finalize() {
|
||||
super.finalize()
|
||||
}
|
||||
}
|
||||
@@ -12,7 +12,7 @@ return super.clone()
|
||||
public open fun toString() : String? {
|
||||
return getJavaClass<Test>.getName() + '@' + Integer.toHexString(hashCode())
|
||||
}
|
||||
protected open fun finalize() : Unit {
|
||||
protected open fun finalize() {
|
||||
super.finalize()
|
||||
}
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun putU<U>(u : U) : Unit {
|
||||
fun putU<U>(u : U) {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun putU<U>(u : U?) : Unit {
|
||||
fun putU<U>(u : U?) {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun putUVW<U, V, W>(u : U, v : V, w : W) : Unit {
|
||||
fun putUVW<U, V, W>(u : U, v : V, w : W) {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun putUVW<U, V, W>(u : U?, v : V?, w : W?) : Unit {
|
||||
fun putUVW<U, V, W>(u : U?, v : V?, w : W?) {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
private fun test() : Unit {
|
||||
private fun test() {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
private fun test() : Unit {
|
||||
private fun test() {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
protected fun test() : Unit {
|
||||
protected fun test() {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
protected fun test() : Unit {
|
||||
protected fun test() {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
public fun test() : Unit {
|
||||
public fun test() {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
public fun test() : Unit {
|
||||
public fun test() {
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun test(vararg var args : Any) : Unit {
|
||||
open fun test(vararg var args : Any) {
|
||||
args = array<Int>(1, 2, 3)
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun test(vararg var args : Any?) : Unit {
|
||||
open fun test(vararg var args : Any?) {
|
||||
args = array<Int?>(1, 2, 3)
|
||||
}
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun popAll(dst : Collection<in E>) : Unit {
|
||||
fun popAll(dst : Collection<in E>) {
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
fun popAll(dst : Collection<in E?>?) : Unit {
|
||||
fun popAll(dst : Collection<in E?>?) {
|
||||
}
|
||||
@@ -11,7 +11,7 @@ private var i : Int = 0
|
||||
/**
|
||||
* This is a function doc comment.
|
||||
*/
|
||||
public open fun foo() : Unit {
|
||||
public open fun foo() {
|
||||
/* This is a function comment */
|
||||
}
|
||||
}
|
||||
@@ -11,7 +11,7 @@ private var i : Int = 0
|
||||
/**
|
||||
* This is a function doc comment.
|
||||
*/
|
||||
public open fun foo() : Unit {
|
||||
public open fun foo() {
|
||||
/* This is a function comment */
|
||||
}
|
||||
}
|
||||
@@ -2,11 +2,11 @@ import java.util.HashMap
|
||||
open class G<T : String>(t : T) {
|
||||
}
|
||||
public open class Java() {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val m = HashMap()
|
||||
m.put(1, 1)
|
||||
}
|
||||
open fun test2() : Unit {
|
||||
open fun test2() {
|
||||
val m = HashMap()
|
||||
val g = G("")
|
||||
val g2 = G<String>("")
|
||||
|
||||
@@ -2,11 +2,11 @@ import java.util.HashMap
|
||||
open class G<T : String?>(t : T?) {
|
||||
}
|
||||
public open class Java() {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var m : HashMap<Any?, Any?>? = HashMap()
|
||||
m?.put(1, 1)
|
||||
}
|
||||
open fun test2() : Unit {
|
||||
open fun test2() {
|
||||
var m : HashMap<*, *>? = HashMap()
|
||||
var g : G<String?>? = G("")
|
||||
var g2 : G<String?>? = G<String?>("")
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
class object {
|
||||
open fun subListRangeCheck(fromIndex : Int, toIndex : Int, size : Int) : Unit {
|
||||
open fun subListRangeCheck(fromIndex : Int, toIndex : Int, size : Int) {
|
||||
if (fromIndex < 0)
|
||||
throw IndexOutOfBoundsException("fromIndex = " + fromIndex)
|
||||
if (toIndex > size)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
class object {
|
||||
open fun subListRangeCheck(fromIndex : Int, toIndex : Int, size : Int) : Unit {
|
||||
open fun subListRangeCheck(fromIndex : Int, toIndex : Int, size : Int) {
|
||||
if (fromIndex < 0)
|
||||
throw IndexOutOfBoundsException("fromIndex = " + fromIndex)
|
||||
if (toIndex > size)
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun putInt(i : Int) : Unit {
|
||||
open fun putInt(i : Int) {
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val b = 10
|
||||
putInt(b.toInt())
|
||||
val b2 = 10
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun putInt(i : Int?) : Unit {
|
||||
open fun putInt(i : Int?) {
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var b : Byte = 10
|
||||
putInt(b.toInt())
|
||||
var b2 : Byte? = 10
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun putInt(i : Int) : Unit {
|
||||
open fun putInt(i : Int) {
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val i = 10
|
||||
putInt(i)
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun putInt(i : Int?) : Unit {
|
||||
open fun putInt(i : Int?) {
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var i : Int = 10
|
||||
putInt(i)
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun putInt(i : Int) : Unit {
|
||||
open fun putInt(i : Int) {
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val b = 10
|
||||
putInt(b.toInt())
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
package demo
|
||||
open class Test() {
|
||||
open fun putInt(i : Int) : Unit {
|
||||
open fun putInt(i : Int) {
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var b : Byte = 10
|
||||
putInt(b.toInt())
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main(args : Array<String>) : Unit {
|
||||
public open fun main(args : Array<String>) {
|
||||
val i1 = Identifier.init<String>("name", false, true)
|
||||
val i2 = Identifier.init<String>("name", false)
|
||||
val i3 = Identifier.init<String>("name")
|
||||
|
||||
@@ -28,7 +28,7 @@ return __
|
||||
}
|
||||
public open class User() {
|
||||
class object {
|
||||
public open fun main(args : Array<String?>?) : Unit {
|
||||
public open fun main(args : Array<String?>?) {
|
||||
var i1 : Identifier<*>? = Identifier.init<String?>("name", false, true)
|
||||
var i2 : Identifier<*>? = Identifier.init<String?>("name", false)
|
||||
var i3 : Identifier<*>? = Identifier.init<String?>("name")
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package demo
|
||||
open class Test(i : Int) {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val i = 10
|
||||
Test(i)
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package demo
|
||||
open class Test(i : Int?) {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var i : Int = 10
|
||||
Test(i)
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package demo
|
||||
open class Test(i : Int) {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val b = 10
|
||||
Test(b.toInt())
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package demo
|
||||
open class Test(i : Int) {
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var b : Byte = 10
|
||||
Test(b.toInt())
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@ open class Test() {
|
||||
open fun getInteger(i : Int) : Int {
|
||||
return i
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
val i = getInteger(10)!!
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,7 @@ open class Test() {
|
||||
open fun getInteger(i : Int?) : Int? {
|
||||
return i
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
var i : Int = getInteger(10)!!
|
||||
}
|
||||
}
|
||||
@@ -10,9 +10,9 @@ var myContainer : Container = Container()
|
||||
open class StringContainer(s : String) {
|
||||
}
|
||||
open class Test() {
|
||||
open fun putString(s : String) : Unit {
|
||||
open fun putString(s : String) {
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
putString(One.myContainer.myString)
|
||||
StringContainer(One.myContainer.myString)
|
||||
}
|
||||
|
||||
@@ -10,9 +10,9 @@ var myContainer : Container? = Container()
|
||||
open class StringContainer(s : String?) {
|
||||
}
|
||||
open class Test() {
|
||||
open fun putString(s : String?) : Unit {
|
||||
open fun putString(s : String?) {
|
||||
}
|
||||
open fun test() : Unit {
|
||||
open fun test() {
|
||||
putString(One.myContainer?.myString)
|
||||
StringContainer(One.myContainer?.myString)
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user