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

@TimedExecution together with @CompileStatic produces compilation error for nested interfaces

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 3.0.5
    • None
    • Compiler
    • None

    Description

      I'm using groovy 3.0.5 as a runtime scripting language for my application. I've got two AST customizers in place:  TimedExecution and CompileStatic. This combination causes the following failure:

      The field 'timedInterrupt998817784$startTime' is not 'public static final' but is defined in interface 'GeneratedScriptingAPI$InnerClass$InnerClass2$InnerClass3$SpecificPropertyFilter'.

      The whole "GeneratedScriptingAPI" is generated at runtime based on certain preferences to provide the user script with a nice and type-safe API. "SpecificPropertyFilter" is an interface:

       

      public interface ${generatedClassName}LinkPropertyFilter extends java.util.function.Predicate<${generatedClassName}Container>{ 
      @Override public boolean test(${generatedClassName}Container container);
      }
      

       

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            martin.haeusler Martin Häusler
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: