Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Transport isUsingAnonymousInnerClass property when transforming constructor call expressions #1078

Conversation

Vampire
Copy link
Member

@Vampire Vampire commented Jan 15, 2020

This propery was not brought over previously.
This works fine for Groovy 2, as the meta class can find the synthetic constructor that is generated for the anonymous inner class.
With Groovy 3 this changed, so without this fix, rewritten anonymous inner class instantiations cannot be executed as the meta class does not find the synthetic constructor anymore.


This change is Reviewable

@codecov
Copy link

codecov bot commented Jan 15, 2020

Codecov Report

Merging #1078 into master will decrease coverage by <.01%.
The diff coverage is 50%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #1078      +/-   ##
============================================
- Coverage     74.01%   74.01%   -0.01%     
  Complexity     3434     3434              
============================================
  Files           382      382              
  Lines         10614    10616       +2     
  Branches       1297     1297              
============================================
+ Hits           7856     7857       +1     
- Misses         2294     2295       +1     
  Partials        464      464
Impacted Files Coverage Δ Complexity Δ
...rk/compiler/ExpressionReplacingVisitorSupport.java 0% <0%> (ø) 0 <0> (ø) ⬇️
...org/spockframework/compiler/ConditionRewriter.java 56.93% <100%> (+0.12%) 44 <0> (ø) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d276e78...ab53433. Read the comment docs.

Copy link
Member

@leonard84 leonard84 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks sensible to me

@leonard84 leonard84 merged commit 0237b8d into spockframework:master Jan 15, 2020
@Vampire Vampire deleted the anonymous-inner-class-constructor-in-ast-transformation branch January 15, 2020 14:39
szpak added a commit that referenced this pull request Jan 15, 2020
szpak added a commit that referenced this pull request Jan 15, 2020
szpak added a commit that referenced this pull request Feb 6, 2020
szpak added a commit that referenced this pull request Feb 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants