You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Eric Milles (Jira)" <ji...@apache.org> on 2019/11/25 19:03:00 UTC
[jira] [Resolved] (GROOVY-8648) Compound assignment to attribute
fails with ASM error
[ https://issues.apache.org/jira/browse/GROOVY-8648?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Eric Milles resolved GROOVY-8648.
---------------------------------
Fix Version/s: 4.x
Resolution: Fixed
> Compound assignment to attribute fails with ASM error
> -----------------------------------------------------
>
> Key: GROOVY-8648
> URL: https://issues.apache.org/jira/browse/GROOVY-8648
> Project: Groovy
> Issue Type: Bug
> Components: class generator
> Affects Versions: 2.4.14, 2.5.0
> Reporter: John Wagenleitner
> Assignee: Eric Milles
> Priority: Major
> Fix For: 4.x
>
>
> The following will fail with 2.4.14 and above.
> {code:java}
> class Account {
> int balance = 0
> void credit(int add) {
> this.@balance += add
> }
> }
> def acct = new Account()
> acct.credit(3)
> assert acct.balance == 3
> {code}
> Fails with the following in 2.5.0
> {code:java}
> groovy.lang.GroovyRuntimeException: ASM reporting processing error for Account#credit with signature void credit(int)
> {code}
> And this starting in 2.4.14
> {code:java}
> java.lang.VerifyError: (class: Account, method: credit signature: (I)V) Unable to pop operand off an empty stack
> {code}
> Possibly related to the fixes for GROOVY-8385 and the operand stack not being marked to handle the compound assignment operators.
> Issue reported on the [dev mailing list|https://mail-archives.apache.org/mod_mbox/groovy-dev/201806.mbox/%3Cef1093fea2ceab17b52fc021631b7b2b5e86ca4e.camel%40winder.org.uk%3E].
--
This message was sent by Atlassian Jira
(v8.3.4#803005)