Skip to content

Commit

Permalink
GROOVY-10457
Browse files Browse the repository at this point in the history
  • Loading branch information
eric-milles committed Jan 21, 2022
1 parent 5bd1319 commit 62fedca
Show file tree
Hide file tree
Showing 5 changed files with 1,200 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7214,4 +7214,23 @@ public void testCompileStatic10424() {

runConformTest(sources, "works");
}

@Test
public void testCompileStatic10457() {
//@formatter:off
String[] sources = {
"Main.groovy",
"@groovy.transform.CompileStatic\n" +
"class C {\n" +
" @groovy.transform.CompileDynamic\n" +
" C() {\n" +
" print(new StringReader('works').text)\n" +
" }\n" +
"}\n" +
"new C()\n",
};
//@formatter:on

runConformTest(sources, "works");
}
}
1 change: 1 addition & 0 deletions base/org.codehaus.groovy30/.checkstyle
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@
<file-match-pattern match-pattern="groovy/transform/NamedVariantASTTransformation.java" include-pattern="false" />
<file-match-pattern match-pattern="groovy/transform/NullCheckASTTransformation.java" include-pattern="false" />
<file-match-pattern match-pattern="groovy/transform/TupleConstructorASTTransformation.java" include-pattern="false" />
<file-match-pattern match-pattern="groovy/transform/sc/StaticCompilationVisitor.java" include-pattern="false" />
<file-match-pattern match-pattern="groovy/transform/sc/TemporaryVariableExpression.java" include-pattern="false" />
<file-match-pattern match-pattern="groovy/transform/sc/transformers/(Binary|Boolean|MethodCall)ExpressionTransformer.java" include-pattern="false" />
<file-match-pattern match-pattern="groovy/transform/sc/transformers/CompareIdentityExpression.java" include-pattern="false" />
Expand Down
Loading

0 comments on commit 62fedca

Please sign in to comment.