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

GroovyConsole AST Viewer fails when trying to display AST for inner classes and anonymous inner classes

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.7-beta-1
    • 1.7-rc-1
    • Groovy Console
    • None
    • WinXP

    Description

      GroovyConsole has an AST Viewer. It just comes up blank when I enter the following script:

      class Foo {
        static class Bar {
        }
      }
      

      There is no exception and no error, it's just blank. No StatementBlock and no Script class either. Just blank.

      This same things happens for anonymous inner classes:

      Timer timer = new Timer()
      
      boolean called = false
      
      timer.schedule(new TimerTask() {
        void run() {
            println "Task executed"
            called = true
        }
      }, 0)
      sleep 100
      
      assert called
      

      Attachments

        Activity

          People

            hamletdrc Hamlet D'Arcy
            hamletdrc Hamlet D'Arcy
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 2m
                2m
                Remaining:
                Remaining Estimate - 2m
                2m
                Logged:
                Time Spent - Not Specified
                Not Specified