Regenerate tests for JS reserved words

This commit is contained in:
Zalim Bashorov
2015-09-18 19:29:03 +03:00
committed by Dmitry Jemerov
parent a1979b6eb4
commit 98867addc9
185 changed files with 1435 additions and 1314 deletions
File diff suppressed because it is too large Load Diff
+45
View File
@@ -0,0 +1,45 @@
NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
dataClass / param
dataClass / val
dataClass / var
delegated / fun
delegated / funParam
delegated / label
delegated / val
delegated / var
enum / entry
enum / fun
enum / funParam
enum / label
enum / val
enum / var
insideClass / fun
insideClass / funParam
insideClass / label
insideClass / val
insideClass / var
insideClassObject / fun
insideClassObject / funParam
insideClassObject / label
insideClassObject / val
insideClassObject / var
insideObject / fun
insideObject / funParam
insideObject / label
insideObject / val
insideObject / var
local / catch
local / fun
local / funParam
local / label
local / val
local / var
toplevel / class
toplevel / enum
toplevel / fun
toplevel / funParam
toplevel / interface
toplevel / label
toplevel / object
toplevel / val
toplevel / var
@@ -2,9 +2,9 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(`for`: String) { data class DataClass(`else`: String) {
init { init {
testRenamed("for", { `for` }) testRenamed("else", { `else` })
} }
} }
@@ -2,9 +2,9 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(NaN: String) { data class DataClass(`false`: String) {
init { init {
testRenamed("NaN", { NaN }) testRenamed("false", { `false` })
} }
} }
@@ -0,0 +1,15 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(Infinity: String) {
init {
testRenamed("Infinity", { Infinity })
}
}
fun box(): String {
DataClass("123")
return "OK"
}
@@ -2,9 +2,9 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(`if`: String) { data class DataClass(Kotlin: String) {
init { init {
testRenamed("if", { `if` }) testRenamed("Kotlin", { Kotlin })
} }
} }
@@ -0,0 +1,15 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(val `break`: String) {
init {
testNotRenamed("break", { `break` })
}
}
fun box(): String {
DataClass("123")
return "OK"
}
@@ -2,17 +2,14 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo { data class DataClass(val `class`: String) {
BAR; init {
var `class`: Int = 0
fun test() {
testNotRenamed("class", { `class` }) testNotRenamed("class", { `class` })
} }
} }
fun box(): String { fun box(): String {
Foo.BAR.test() DataClass("123")
return "OK" return "OK"
} }
@@ -2,9 +2,9 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(arguments: String) { data class DataClass(val undefined: String) {
init { init {
testRenamed("arguments", { arguments }) testNotRenamed("undefined", { undefined })
} }
} }
@@ -0,0 +1,15 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(val void: String) {
init {
testNotRenamed("void", { void })
}
}
fun box(): String {
DataClass("123")
return "OK"
}
@@ -2,7 +2,7 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(val `continue`: String) { data class DataClass(var `continue`: String) {
init { init {
testNotRenamed("continue", { `continue` }) testNotRenamed("continue", { `continue` })
} }
@@ -2,7 +2,7 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(val `do`: String) { data class DataClass(var `do`: String) {
init { init {
testNotRenamed("do", { `do` }) testNotRenamed("do", { `do` })
} }
@@ -1,15 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(var `else`: String) {
init {
testNotRenamed("else", { `else` })
}
}
fun box(): String {
DataClass("123")
return "OK"
}
@@ -1,15 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(var `false`: String) {
init {
testNotRenamed("false", { `false` })
}
}
fun box(): String {
DataClass("123")
return "OK"
}
@@ -1,15 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(var Infinity: String) {
init {
testNotRenamed("Infinity", { Infinity })
}
}
fun box(): String {
DataClass("123")
return "OK"
}
@@ -1,15 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(var Kotlin: String) {
init {
testNotRenamed("Kotlin", { Kotlin })
}
}
fun box(): String {
DataClass("123")
return "OK"
}
@@ -2,7 +2,7 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(val with: String) { data class DataClass(var with: String) {
init { init {
testNotRenamed("with", { with }) testNotRenamed("with", { with })
} }
@@ -2,7 +2,7 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
data class DataClass(val yield: String) { data class DataClass(var yield: String) {
init { init {
testNotRenamed("yield", { yield }) testNotRenamed("yield", { yield })
} }
@@ -2,17 +2,19 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
fun default() fun catch()
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override fun default() { default() } override fun catch() {
catch()
}
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testNotRenamed("default", { ::default }) testNotRenamed("catch", { ::catch })
} }
} }
@@ -20,4 +22,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,17 +2,19 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
fun `return`() fun const()
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override fun `return`() { `return`() } override fun const() {
const()
}
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testNotRenamed("return", { ::`return` }) testNotRenamed("const", { ::const })
} }
} }
@@ -20,4 +22,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,17 +2,19 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
fun `super`() fun `null`()
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override fun `super`() { `super`() } override fun `null`() {
`null`()
}
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testNotRenamed("super", { ::`super` }) testNotRenamed("null", { ::`null` })
} }
} }
@@ -20,4 +22,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -0,0 +1,25 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
interface Trait {
fun `package`()
}
class TraitImpl : Trait {
override fun `package`() {
`package`()
}
}
class TestDelegate : Trait by TraitImpl() {
fun test() {
testNotRenamed("package", { ::`package` })
}
}
fun box(): String {
TestDelegate().test()
return "OK"
}
@@ -2,15 +2,15 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
fun foo(enum: String) fun foo(debugger: String)
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override fun foo(enum: String) { override fun foo(debugger: String) {
assertEquals("123", enum) assertEquals("123", debugger)
testRenamed("enum", { enum }) testRenamed("debugger", { debugger })
} }
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
@@ -23,4 +23,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,15 +2,15 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
fun foo(`throw`: String) fun foo(default: String)
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override fun foo(`throw`: String) { override fun foo(default: String) {
assertEquals("123", `throw`) assertEquals("123", default)
testRenamed("throw", { `throw` }) testRenamed("default", { default })
} }
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
@@ -23,4 +23,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,15 +2,15 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
fun foo(delete: String) fun foo(`return`: String)
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override fun foo(delete: String) { override fun foo(`return`: String) {
assertEquals("123", delete) assertEquals("123", `return`)
testRenamed("delete", { delete }) testRenamed("return", { `return` })
} }
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
@@ -23,4 +23,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,15 +2,15 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
fun foo(`this`: String) fun foo(`super`: String)
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override fun foo(`this`: String) { override fun foo(`super`: String) {
assertEquals("123", `this`) assertEquals("123", `super`)
testRenamed("this", { `this` }) testRenamed("super", { `super` })
} }
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
@@ -23,4 +23,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,7 +2,7 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
val t: Int val t: Int
} }
@@ -12,7 +12,10 @@ class TraitImpl : Trait {
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testRenamed("true", { `true`@ while (false) {} }) testRenamed("delete", {
delete@ while (false) {
}
})
} }
} }
@@ -20,4 +23,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,7 +2,7 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
val t: Int val t: Int
} }
@@ -12,7 +12,10 @@ class TraitImpl : Trait {
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testRenamed("eval", { eval@ while (false) {} }) testRenamed("enum", {
enum@ while (false) {
}
})
} }
} }
@@ -20,4 +23,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,7 +2,7 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
val t: Int val t: Int
} }
@@ -12,7 +12,10 @@ class TraitImpl : Trait {
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testRenamed("export", { export@ while (false) {} }) testRenamed("this", {
`this`@ while (false) {
}
})
} }
} }
@@ -20,4 +23,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,7 +2,7 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
val t: Int val t: Int
} }
@@ -12,7 +12,10 @@ class TraitImpl : Trait {
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testRenamed("try", { `try`@ while (false) {} }) testRenamed("throw", {
`throw`@ while (false) {
}
})
} }
} }
@@ -20,4 +23,4 @@ fun box(): String {
TestDelegate().test() TestDelegate().test()
return "OK" return "OK"
} }
@@ -2,17 +2,17 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
fun debugger() val arguments: Int
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override fun debugger() { debugger() } override val arguments: Int = 0
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testNotRenamed("debugger", { ::debugger }) testNotRenamed("arguments", { arguments })
} }
} }
@@ -0,0 +1,23 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
interface Trait {
val `for`: Int
}
class TraitImpl : Trait {
override val `for`: Int = 0
}
class TestDelegate : Trait by TraitImpl() {
fun test() {
testNotRenamed("for", { `for` })
}
}
fun box(): String {
TestDelegate().test()
return "OK"
}
@@ -2,17 +2,17 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
var catch: Int val `if`: Int
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override var catch: Int = 0 override val `if`: Int = 0
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
fun test() { fun test() {
testNotRenamed("catch", { catch }) testNotRenamed("if", { `if` })
} }
} }
@@ -0,0 +1,23 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
interface Trait {
val NaN: Int
}
class TraitImpl : Trait {
override val NaN: Int = 0
}
class TestDelegate : Trait by TraitImpl() {
fun test() {
testNotRenamed("NaN", { NaN })
}
}
fun box(): String {
TestDelegate().test()
return "OK"
}
@@ -2,12 +2,12 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
val await: Int var await: Int
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override val await: Int = 0 override var await: Int = 0
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
@@ -2,12 +2,12 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
val case: Int var case: Int
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override val case: Int = 0 override var case: Int = 0
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
@@ -1,23 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait {
var const: Int
}
class TraitImpl : Trait {
override var const: Int = 0
}
class TestDelegate : Trait by TraitImpl() {
fun test() {
testNotRenamed("const", { const })
}
}
fun box(): String {
TestDelegate().test()
return "OK"
}
@@ -2,12 +2,12 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
val `in`: Int var `in`: Int
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override val `in`: Int = 0 override var `in`: Int = 0
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
@@ -2,12 +2,12 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait { interface Trait {
val `interface`: Int var `interface`: Int
} }
class TraitImpl : Trait { class TraitImpl : Trait {
override val `interface`: Int = 0 override var `interface`: Int = 0
} }
class TestDelegate : Trait by TraitImpl() { class TestDelegate : Trait by TraitImpl() {
@@ -1,23 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait {
var `null`: Int
}
class TraitImpl : Trait {
override var `null`: Int = 0
}
class TestDelegate : Trait by TraitImpl() {
fun test() {
testNotRenamed("null", { `null` })
}
}
fun box(): String {
TestDelegate().test()
return "OK"
}
@@ -1,23 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
trait Trait {
var `package`: Int
}
class TraitImpl : Trait {
override var `package`: Int = 0
}
class TestDelegate : Trait by TraitImpl() {
fun test() {
testNotRenamed("package", { `package` })
}
}
fun box(): String {
TestDelegate().test()
return "OK"
}
@@ -3,11 +3,11 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo { enum class Foo {
static `for`
} }
fun box(): String { fun box(): String {
testNotRenamed("static", { Foo.static }) testNotRenamed("for", { Foo.`for` })
return "OK" return "OK"
} }
@@ -3,11 +3,11 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo { enum class Foo {
`in` `if`
} }
fun box(): String { fun box(): String {
testNotRenamed("in", { Foo.`in` }) testNotRenamed("if", { Foo.`if` })
return "OK" return "OK"
} }
@@ -3,11 +3,11 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo { enum class Foo {
`public` `private`
} }
fun box(): String { fun box(): String {
testNotRenamed("public", { Foo.`public` }) testNotRenamed("private", { Foo.`private` })
return "OK" return "OK"
} }
@@ -3,11 +3,11 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo { enum class Foo {
`interface` `protected`
} }
fun box(): String { fun box(): String {
testNotRenamed("interface", { Foo.`interface` }) testNotRenamed("protected", { Foo.`protected` })
return "OK" return "OK"
} }
@@ -4,10 +4,13 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
fun `continue`() { `continue`() }
fun `break`() {
`break`()
}
fun test() { fun test() {
testNotRenamed("continue", { ::`continue` }) testNotRenamed("break", { ::`break` })
} }
} }
@@ -15,4 +18,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,13 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
fun import() { import() }
fun `class`() {
`class`()
}
fun test() { fun test() {
testNotRenamed("import", { ::import }) testNotRenamed("class", { ::`class` })
} }
} }
@@ -15,4 +18,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,13 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
fun instanceof() { instanceof() }
fun function() {
function()
}
fun test() { fun test() {
testNotRenamed("instanceof", { ::instanceof }) testNotRenamed("function", { ::function })
} }
} }
@@ -15,4 +18,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,13 +4,13 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
fun foo(let: String) {
assertEquals("123", let) fun implements() {
testRenamed("let", { let }) implements()
} }
fun test() { fun test() {
foo("123") testNotRenamed("implements", { ::implements })
} }
} }
@@ -18,4 +18,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,11 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
fun foo(new: String) {
assertEquals("123", new) fun foo(`continue`: String) {
testRenamed("new", { new }) assertEquals("123", `continue`)
} testRenamed("continue", { `continue` })
}
fun test() { fun test() {
foo("123") foo("123")
@@ -18,4 +19,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,11 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
fun foo(`else`: String) {
assertEquals("123", `else`) fun foo(`do`: String) {
testRenamed("else", { `else` }) assertEquals("123", `do`)
} testRenamed("do", { `do` })
}
fun test() { fun test() {
foo("123") foo("123")
@@ -18,4 +19,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,11 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
fun foo(`false`: String) {
assertEquals("123", `false`) fun foo(import: String) {
testRenamed("false", { `false` }) assertEquals("123", import)
} testRenamed("import", { import })
}
fun test() { fun test() {
foo("123") foo("123")
@@ -18,4 +19,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -0,0 +1,22 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo {
BAR;
fun foo(instanceof: String) {
assertEquals("123", instanceof)
testRenamed("instanceof", { instanceof })
}
fun test() {
foo("123")
}
}
fun box(): String {
Foo.BAR.test()
return "OK"
}
@@ -4,10 +4,14 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("for", { `for`@ while (false) {} }) testRenamed("else", {
`else`@ while (false) {
}
})
} }
} }
@@ -15,4 +19,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,14 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("if", { `if`@ while (false) {} }) testRenamed("false", {
`false`@ while (false) {
}
})
} }
} }
@@ -15,4 +19,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,14 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("private", { private@ while (false) {} }) testRenamed("let", {
let@ while (false) {
}
})
} }
} }
@@ -15,4 +19,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,14 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("protected", { protected@ while (false) {} }) testRenamed("new", {
new@ while (false) {
}
})
} }
} }
@@ -15,4 +19,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,10 +4,11 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
fun `do`() { `do`() }
val eval: Int = 0
fun test() { fun test() {
testNotRenamed("do", { ::`do` }) testNotRenamed("eval", { eval })
} }
} }
@@ -15,4 +16,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -0,0 +1,19 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo {
BAR;
val export: Int = 0
fun test() {
testNotRenamed("export", { export })
}
}
fun box(): String {
Foo.BAR.test()
return "OK"
}
@@ -4,10 +4,11 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
var `break`: Int = 0
val `true`: Int = 0
fun test() { fun test() {
testNotRenamed("break", { `break` }) testNotRenamed("true", { `true` })
} }
} }
@@ -15,4 +16,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -0,0 +1,19 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo {
BAR;
val `try`: Int = 0
fun test() {
testNotRenamed("try", { `try` })
}
}
fun box(): String {
Foo.BAR.test()
return "OK"
}
@@ -4,7 +4,8 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
val extends: Int = 0
var extends: Int = 0
fun test() { fun test() {
testNotRenamed("extends", { extends }) testNotRenamed("extends", { extends })
@@ -15,4 +16,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,7 +4,8 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
val finally: Int = 0
var finally: Int = 0
fun test() { fun test() {
testNotRenamed("finally", { finally }) testNotRenamed("finally", { finally })
@@ -15,4 +16,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -1,18 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo {
BAR;
var function: Int = 0
fun test() {
testNotRenamed("function", { function })
}
}
fun box(): String {
Foo.BAR.test()
return "OK"
}
@@ -1,18 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
enum class Foo {
BAR;
var implements: Int = 0
fun test() {
testNotRenamed("implements", { implements })
}
}
fun box(): String {
Foo.BAR.test()
return "OK"
}
@@ -4,7 +4,8 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
val `var`: Int = 0
var `var`: Int = 0
fun test() { fun test() {
testNotRenamed("var", { `var` }) testNotRenamed("var", { `var` })
@@ -15,4 +16,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -4,7 +4,8 @@ package foo
enum class Foo { enum class Foo {
BAR; BAR;
val `while`: Int = 0
var `while`: Int = 0
fun test() { fun test() {
testNotRenamed("while", { `while` }) testNotRenamed("while", { `while` })
@@ -15,4 +16,4 @@ fun box(): String {
Foo.BAR.test() Foo.BAR.test()
return "OK" return "OK"
} }
@@ -0,0 +1,19 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass {
fun arguments() {
arguments()
}
fun test() {
testNotRenamed("arguments", { ::arguments })
}
}
fun box(): String {
TestClass().test()
return "OK"
}
@@ -3,10 +3,12 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass { class TestClass {
fun `try`() { `try`() } fun NaN() {
NaN()
}
fun test() { fun test() {
testNotRenamed("try", { ::`try` }) testNotRenamed("NaN", { ::NaN })
} }
} }
@@ -14,4 +16,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -3,10 +3,10 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass { class TestClass {
fun foo(catch: String) { fun foo(await: String) {
assertEquals("123", catch) assertEquals("123", await)
testRenamed("catch", { catch }) testRenamed("await", { await })
} }
fun test() { fun test() {
foo("123") foo("123")
@@ -17,4 +17,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -3,10 +3,10 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass { class TestClass {
fun foo(`var`: String) { fun foo(case: String) {
assertEquals("123", `var`) assertEquals("123", case)
testRenamed("var", { `var` }) testRenamed("case", { case })
} }
fun test() { fun test() {
foo("123") foo("123")
@@ -17,4 +17,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -3,10 +3,10 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass { class TestClass {
fun foo(const: String) { fun foo(`true`: String) {
assertEquals("123", const) assertEquals("123", `true`)
testRenamed("const", { const }) testRenamed("true", { `true` })
} }
fun test() { fun test() {
foo("123") foo("123")
@@ -17,4 +17,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -3,10 +3,10 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass { class TestClass {
fun foo(`while`: String) { fun foo(`try`: String) {
assertEquals("123", `while`) assertEquals("123", `try`)
testRenamed("while", { `while` }) testRenamed("try", { `try` })
} }
fun test() { fun test() {
foo("123") foo("123")
@@ -17,4 +17,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -3,10 +3,12 @@ package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT! // NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass { class TestClass {
fun `true`() { `true`() } fun `this`() {
`this`()
}
fun test() { fun test() {
testNotRenamed("true", { ::`true` }) testNotRenamed("this", { ::`this` })
} }
} }
@@ -14,4 +16,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -0,0 +1,19 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass {
fun `throw`() {
`throw`()
}
fun test() {
testNotRenamed("throw", { ::`throw` })
}
}
fun box(): String {
TestClass().test()
return "OK"
}
@@ -6,7 +6,10 @@ class TestClass {
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("class", { `class`@ while (false) {} }) testRenamed("catch", {
catch@ while (false) {
}
})
} }
} }
@@ -14,4 +17,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -6,7 +6,10 @@ class TestClass {
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("debugger", { debugger@ while (false) {} }) testRenamed("const", {
const@ while (false) {
}
})
} }
} }
@@ -14,4 +17,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -6,7 +6,10 @@ class TestClass {
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("break", { `break`@ while (false) {} }) testRenamed("var", {
`var`@ while (false) {
}
})
} }
} }
@@ -14,4 +17,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -6,7 +6,10 @@ class TestClass {
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("default", { default@ while (false) {} }) testRenamed("while", {
`while`@ while (false) {
}
})
} }
} }
@@ -14,4 +17,4 @@ fun box(): String {
TestClass().test() TestClass().test()
return "OK" return "OK"
} }
@@ -4,10 +4,12 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
fun finally() { finally() } fun `else`() {
`else`()
}
fun test() { fun test() {
testNotRenamed("finally", { ::finally }) testNotRenamed("else", { ::`else` })
} }
} }
} }
@@ -16,4 +18,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -4,10 +4,12 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
fun extends() { extends() } fun eval() {
eval()
}
fun test() { fun test() {
testNotRenamed("extends", { ::extends }) testNotRenamed("eval", { ::eval })
} }
} }
} }
@@ -16,4 +18,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -0,0 +1,21 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass {
companion object {
fun export() {
export()
}
fun test() {
testNotRenamed("export", { ::export })
}
}
}
fun box(): String {
TestClass.test()
return "OK"
}
@@ -0,0 +1,21 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass {
companion object {
fun `false`() {
`false`()
}
fun test() {
testNotRenamed("false", { ::`false` })
}
}
}
fun box(): String {
TestClass.test()
return "OK"
}
@@ -4,10 +4,10 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
fun foo(`in`: String) { fun foo(extends: String) {
assertEquals("123", `in`) assertEquals("123", extends)
testRenamed("in", { `in` }) testRenamed("extends", { extends })
} }
fun test() { fun test() {
foo("123") foo("123")
@@ -19,4 +19,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -4,10 +4,10 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
fun foo(`interface`: String) { fun foo(finally: String) {
assertEquals("123", `interface`) assertEquals("123", finally)
testRenamed("interface", { `interface` }) testRenamed("finally", { finally })
} }
fun test() { fun test() {
foo("123") foo("123")
@@ -19,4 +19,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -4,10 +4,10 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
fun foo(implements: String) { fun foo(`for`: String) {
assertEquals("123", implements) assertEquals("123", `for`)
testRenamed("implements", { implements }) testRenamed("for", { `for` })
} }
fun test() { fun test() {
foo("123") foo("123")
@@ -19,4 +19,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -4,10 +4,10 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
fun foo(function: String) { fun foo(`if`: String) {
assertEquals("123", function) assertEquals("123", `if`)
testRenamed("function", { function }) testRenamed("if", { `if` })
} }
fun test() { fun test() {
foo("123") foo("123")
@@ -19,4 +19,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -7,7 +7,10 @@ class TestClass {
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("null", { `null`@ while (false) {} }) testRenamed("function", {
function@ while (false) {
}
})
} }
} }
} }
@@ -16,4 +19,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -7,7 +7,10 @@ class TestClass {
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("import", { import@ while (false) {} }) testRenamed("implements", {
implements@ while (false) {
}
})
} }
} }
} }
@@ -16,4 +19,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -7,7 +7,10 @@ class TestClass {
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("package", { `package`@ while (false) {} }) testRenamed("in", {
`in`@ while (false) {
}
})
} }
} }
} }
@@ -16,4 +19,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -7,7 +7,10 @@ class TestClass {
val t: Int = 0 val t: Int = 0
fun test() { fun test() {
testRenamed("instanceof", { instanceof@ while (false) {} }) testRenamed("interface", {
`interface`@ while (false) {
}
})
} }
} }
} }
@@ -16,4 +19,4 @@ fun box(): String {
TestClass.test() TestClass.test()
return "OK" return "OK"
} }
@@ -4,10 +4,10 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
fun `if`() { `if`() } val `break`: Int = 0
fun test() { fun test() {
testNotRenamed("if", { ::`if` }) testNotRenamed("break", { `break` })
} }
} }
} }
@@ -0,0 +1,19 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass {
companion object {
val `class`: Int = 0
fun test() {
testNotRenamed("class", { `class` })
}
}
}
fun box(): String {
TestClass.test()
return "OK"
}
@@ -0,0 +1,19 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass {
companion object {
val debugger: Int = 0
fun test() {
testNotRenamed("debugger", { debugger })
}
}
}
fun box(): String {
TestClass.test()
return "OK"
}
@@ -4,10 +4,10 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
fun `for`() { `for`() } val default: Int = 0
fun test() { fun test() {
testNotRenamed("for", { ::`for` }) testNotRenamed("default", { default })
} }
} }
} }
@@ -4,7 +4,7 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
val `continue`: Int = 0 var `continue`: Int = 0
fun test() { fun test() {
testNotRenamed("continue", { `continue` }) testNotRenamed("continue", { `continue` })
@@ -4,7 +4,7 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
val delete: Int = 0 var delete: Int = 0
fun test() { fun test() {
testNotRenamed("delete", { delete }) testNotRenamed("delete", { delete })
@@ -4,7 +4,7 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
val `do`: Int = 0 var `do`: Int = 0
fun test() { fun test() {
testNotRenamed("do", { `do` }) testNotRenamed("do", { `do` })
@@ -1,19 +0,0 @@
package foo
// NOTE THIS FILE IS AUTO-GENERATED by the generateTestDataForReservedWords.kt. DO NOT EDIT!
class TestClass {
companion object {
var `else`: Int = 0
fun test() {
testNotRenamed("else", { `else` })
}
}
}
fun box(): String {
TestClass.test()
return "OK"
}
@@ -4,7 +4,7 @@ package foo
class TestClass { class TestClass {
companion object { companion object {
val enum: Int = 0 var enum: Int = 0
fun test() { fun test() {
testNotRenamed("enum", { enum }) testNotRenamed("enum", { enum })

Some files were not shown because too many files have changed in this diff Show More