Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-211

Cand have a closure over the parameters of another closure

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.0-beta-3
    • 1.0-beta-4
    • ast builder
    • None

    Description

      c = { x |
      c1 =

      { println x[0] }

      c1()
      }

      c([1])

      produces a null pointer exception

      c = { x |
      xx = x
      c1 =

      { println xx[0] }

      c1()
      }

      c([1])

      works

      Attachments

        Issue Links

          Activity

            People

              jstrachan James Strachan
              tug John Wilson
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: