[
https://issues.apache.org/jira/browse/GROOVY-12292?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18107222#comment-18107222
]
ASF GitHub Bot commented on GROOVY-12292:
-----------------------------------------
codecov-commenter commented on PR #2829:
URL: https://github.com/apache/groovy/pull/2829#issuecomment-5389924635
##
[Codecov](https://app.codecov.io/gh/apache/groovy/pull/2829?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 70.6076%. Comparing base
([`3190f42`](https://app.codecov.io/gh/apache/groovy/commit/3190f42b54556e08d5bd104f53e39f6711438e49?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache))
to head
([`47dffb3`](https://app.codecov.io/gh/apache/groovy/commit/47dffb377e9d4857bbc69b33fb571ba920815c28?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
<details><summary>Additional details and impacted files</summary>
[](https://app.codecov.io/gh/apache/groovy/pull/2829?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
```diff
@@ Coverage Diff @@
## master #2829 +/- ##
==================================================
- Coverage 70.6100% 70.6076% -0.0023%
Complexity 36472 36472
==================================================
Files 1569 1569
Lines 133831 133834 +3
Branches 24666 24667 +1
==================================================
- Hits 94498 94497 -1
- Misses 30821 30823 +2
- Partials 8512 8514 +2
```
| [Files with missing
lines](https://app.codecov.io/gh/apache/groovy/pull/2829?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/2829?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)
| `87.2602% <100.0000%> (+0.0094%)` | :arrow_up: |
... and [7 files with indirect coverage
changes](https://app.codecov.io/gh/apache/groovy/pull/2829/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>
> Various combinations of type-checking and static-compilation do not correctly
> combine
> -------------------------------------------------------------------------------------
>
> Key: GROOVY-12292
> URL: https://issues.apache.org/jira/browse/GROOVY-12292
> Project: Groovy
> Issue Type: Bug
> Affects Versions: 2.5.23, 3.0.25, 5.0.3, 4.0.31
> Reporter: Björn Kautler
> Assignee: Paul King
> Priority: Major
> Labels: breaking
>
> Given this code:
> https://groovyconsole.dev/?g=groovy_5_0&codez=eNrtkl8LgjAUxd_3KS4-6YvSv_fAXiKCQL_AmqtG6WQbgYTfPTXNWqUWRAXt8XLO2bk_LgtjLhSsBef7xFYCR3LFRWi7PIzZjk6SCIeMINYs8xRWDSo_iam7oWRLg0ojC0eDlEXrOQ-o7c2mC4TGWh-yw1KCT6XqwQFB9sbXVfJRQFeATasUABiGrbinRBYtTasYpuiO2cz_tM4Ry24Rl0tWVvLQCo4D5PQpUCG4eJSllQnayqQ1rBJFzaqvsapo_mFp29TIBm9A9sOwLqvUkIYvQ2ou-yy1J9K05T-P8-byRl9wea8haz3eDmyOjbPXaQ
> {code:groovy}
> import groovy.transform.CompileDynamic
> import groovy.transform.CompileStatic
> import groovy.transform.TypeChecked
> import static groovy.transform.TypeCheckingMode.SKIP
> @CompileDynamic
> class Test1 {
> @CompileStatic
> def a() {
> "".toStrings()
> }
> @CompileStatic(SKIP)
> def b() {
> "".toStrings()
> }
> @TypeChecked
> def c() {
> "".toStrings() // compile error
> }
> @TypeChecked(SKIP)
> def d() {
> "".toStrings()
> }
> }
> @CompileStatic
> class Test2 {
> @CompileDynamic
> def a() {
> "".toStrings()
> }
> @CompileStatic(SKIP)
> def b() {
> "".toStrings()
> }
> @TypeChecked
> def c() {
> "".toStrings() // compile error
> }
> @TypeChecked(SKIP)
> def d() {
> "".toStrings()
> }
> }
> @CompileStatic(SKIP)
> class Test3 {
> @CompileDynamic
> def a() {
> "".toStrings()
> }
> @CompileStatic
> def b() {
> "".toStrings()
> }
> @TypeChecked
> def c() {
> "".toStrings() // compile error
> }
> @TypeChecked(SKIP)
> def d() {
> "".toStrings()
> }
> }
> @TypeChecked
> class Test4 {
> @CompileDynamic
> def a() {
> "".toStrings() // compile error
> }
> @CompileStatic
> def b() {
> "".toStrings() // compile error
> }
> @CompileStatic(SKIP)
> def c() {
> "".toStrings() // compile error
> }
> @TypeChecked(SKIP)
> def d() {
> "".toStrings()
> }
> }
> @TypeChecked(SKIP)
> class Test5 {
> @CompileDynamic
> def a() {
> "".toStrings()
> }
> @CompileStatic
> def b() {
> "".toStrings()
> }
> @CompileStatic(SKIP)
> def c() {
> "".toStrings()
> }
> @TypeChecked
> def d() {
> "".toStrings()
> }
> }
> {code}
> I'd say the annotations do not combine correctly.
> For example {{@CompileDynamic}} or {{@CompileStatic(SKIP)}} or
> {{@TypeChecked(SKIP)}} on class and {{@CompileStatic}} on method does not do
> type-check?
> And also {{@TypeChecked(SKIP)}} on class and {{@TypeChecked}} on method does
> not do type-check?
> At least those 4 combinations appear to be fishy to me.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)