Hi. Following code results in syntactically incorr...
# announcements
v
Hi. Following code results in syntactically incorrect JavaScript:
Copy code
fun test1() {
    val f = fun() {
        val g = fun() {
            println("i am g")
        }

        println("i am f")
        g()
    }

    println("i am test1")
    f()
}
Resulting JS:
Copy code
<no name provided>$f: function () {
      Kotlin.println('i am g');
    },
    test1$f: function () {
      var g = _.<no name provided>$f;
      Kotlin.println('i am f');
      g();
    },
    test1: function () {
      var f = _.test1$f;
      Kotlin.println('i am test1');
      f();
    },
Problem is both on current stable and EAP.