Java to Kotlin converter: do not generate redundant parenthesis for empty constructor parameters
This commit is contained in:
@@ -8,7 +8,7 @@ import java.util.ArrayList
|
||||
// we need ArrayList
|
||||
|
||||
// let's declare a class:
|
||||
class A /* just a sample name*/() : Runnable /* let's implement Runnable */ {
|
||||
class A /* just a sample name*/ : Runnable /* let's implement Runnable */ {
|
||||
fun foo/* again a sample name */(p: Int /* parameter p */, c: Char /* parameter c */) {
|
||||
// let's print something:
|
||||
System.out.println("1") // print 1
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package foo
|
||||
|
||||
class A() {
|
||||
class A {
|
||||
fun /* nothing to return */ foo(/* no parameters at all */) {
|
||||
// let declare a variable
|
||||
// with 2 comments before
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
class A() {
|
||||
class A {
|
||||
private val isOpen = true // ideally should be atomic boolean
|
||||
}
|
||||
Reference in New Issue
Block a user