[
https://issues.apache.org/jira/browse/GROOVY-12668?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18137487#comment-18137487
]
ASF GitHub Bot commented on GROOVY-12668:
-----------------------------------------
codecov-commenter commented on PR #3189:
URL: https://github.com/apache/groovy/pull/3189#issuecomment-6611850989
##
[Codecov](https://app.codecov.io/gh/apache/groovy/pull/3189?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
Report
:white_check_mark: All modified and coverable lines are covered by tests.
:white_check_mark: Project coverage is 74.1475%. Comparing base
([`0941dba`](https://app.codecov.io/gh/apache/groovy/commit/0941dbacf496a1667c27681c6fe76deee59bfb57?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache))
to head
([`70adb67`](https://app.codecov.io/gh/apache/groovy/commit/70adb67835cf3580d12b4a6e94a458fd44d00a47?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
:warning: Report is 11 commits behind head on master.
<details><summary>Additional details and impacted files</summary>
[](https://app.codecov.io/gh/apache/groovy/pull/3189?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
```diff
@@ Coverage Diff @@
## master #3189 +/- ##
==================================================
- Coverage 74.1533% 74.1475% -0.0058%
- Complexity 43751 43754 +3
==================================================
Files 1692 1692
Lines 149516 149525 +9
Branches 28366 28369 +3
==================================================
- Hits 110871 110869 -2
- Misses 28448 28453 +5
- Partials 10197 10203 +6
```
| [Files with missing
lines](https://app.codecov.io/gh/apache/groovy/pull/3189?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
| Coverage Δ | |
|---|---|---|
|
[...roovy/transform/stc/StaticTypeCheckingVisitor.java](https://app.codecov.io/gh/apache/groovy/pull/3189?src=pr&el=tree&filepath=src%2Fmain%2Fjava%2Forg%2Fcodehaus%2Fgroovy%2Ftransform%2Fstc%2FStaticTypeCheckingVisitor.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c3JjL21haW4vamF2YS9vcmcvY29kZWhhdXMvZ3Jvb3Z5L3RyYW5zZm9ybS9zdGMvU3RhdGljVHlwZUNoZWNraW5nVmlzaXRvci5qYXZh)
| `88.2403% <100.0000%> (+0.0224%)` | :arrow_up: |
... and [12 files with indirect coverage
changes](https://app.codecov.io/gh/apache/groovy/pull/3189/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
</details>
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test
Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests,
report on failures, and find test suite problems.
- :package: [JS Bundle
Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save
yourself from yourself by tracking and limiting bundle sizes in JS merges.
</details>
> SC calls the Closure method instead of the enclosing class method of the same
> name from a lambda
> ------------------------------------------------------------------------------------------------
>
> Key: GROOVY-12668
> URL: https://issues.apache.org/jira/browse/GROOVY-12668
> Project: Groovy
> Issue Type: Bug
> Affects Versions: 5.0.8, 7.0.0-alpha-1, 6.0.0
> Reporter: Scott Murphy Heiberg
> Priority: Major
>
> {code:groovy}
> import groovy.transform.CompileStatic
> import java.util.function.Supplier
> @CompileStatic
> class C {
> String getDelegate() { 'Cd' }
> String memoizeAtMost(int i) { 'C' + i }
> def m() {
> Supplier<Object> s = () -> getDelegate()
> Supplier<Object> t = () -> memoizeAtMost(2)
> [s.get(), t.get()]
> }
> }
> println new C().m()
> {code}
> *Actual* (5.0.8, 6.0.0, master): {{[C@6d1310f6,
> org.codehaus.groovy.runtime.memoize.Memoize$MemoizeFunction@3228d990]}}. The
> calls go to the lambda object's {{Closure.getDelegate()}} and
> {{Closure.memoizeAtMost(int)}}. With {{curry(1)}}, {{rcurry}} or {{ncurry}}
> declared in the class, compilation fails with "Reference to method is
> ambiguous ... Closure#curry".
> *Expected* (as in 4.0.33): {{[Cd, C2]}}. The enclosing class's methods are
> called, static ones included.
> Since GROOVY-11386, the type checker looks up an implicit-this call in a
> closure or lambda on {{Closure}} before the owner and the delegate. A lambda
> in statically compiled code follows Java semantics, so the enclosing class
> should come first. A lambda in dynamic or @TypeChecked code is a closure at
> run time, where the closure's own methods do come first.
> Verified: 5.0.8, 6.0.0 and master affected; 4.0.33 not affected.
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)