Nashorn: let & const declarations are not shared between scripts

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P3
    • 8u40
    • Affects Version/s: 8u40, 9
    • Component/s: core-libs
    • None
    • Environment:

      jdk 1.9.0-internal-sqe_2014_09_05_16_59-b00

    • b17
    • generic
    • generic

        I tried with jjs
        $ jjs --language=es6
        jjs> var x = 2;
        jjs> let a = 1;
        jjs> x
        2
        jjs> a
        <shell>:1 ReferenceError: "a" is not defined
        jjs>

              Assignee:
              Hannes Wallnoefer
              Reporter:
              Sergey Lugovoy (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: