Files
kotlin-fork/js/js.translator/testData/lineNumbers/optionalArgs.kt
T
Alexey Andreev 4332f1cb2c Don't share instances of JsNameRef nodes to avoid wrong source maps
When to name references to the same name are represented by
a shared JS AST node, setting line number of the second usage may
override line number of the first usage.

Also, supply more JS AST nodes related to default parameters,
with corresponding source information.
2017-05-30 12:12:30 +03:00

10 lines
125 B
Kotlin
Vendored

fun box(
x: Int = 23,
y: Int =
42
) {
println(x)
println(y)
}
// LINES: 2 2 3 4 6 7