Repository: groovy
Updated Branches:
  refs/heads/GROOVY_2_4_X 3c6e917e3 -> 787845fc9


inline functionality not in 2_4_X


Project: http://git-wip-us.apache.org/repos/asf/groovy/repo
Commit: http://git-wip-us.apache.org/repos/asf/groovy/commit/787845fc
Tree: http://git-wip-us.apache.org/repos/asf/groovy/tree/787845fc
Diff: http://git-wip-us.apache.org/repos/asf/groovy/diff/787845fc

Branch: refs/heads/GROOVY_2_4_X
Commit: 787845fc91e10626379ee85614cef93bd75f9631
Parents: 3c6e917
Author: paulk <pa...@asert.com.au>
Authored: Thu Feb 8 20:51:34 2018 +1000
Committer: paulk <pa...@asert.com.au>
Committed: Thu Feb 8 20:51:51 2018 +1000

----------------------------------------------------------------------
 src/main/org/codehaus/groovy/classgen/AsmClassGenerator.java | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/groovy/blob/787845fc/src/main/org/codehaus/groovy/classgen/AsmClassGenerator.java
----------------------------------------------------------------------
diff --git a/src/main/org/codehaus/groovy/classgen/AsmClassGenerator.java 
b/src/main/org/codehaus/groovy/classgen/AsmClassGenerator.java
index 36f6e2e..e821f1b 100644
--- a/src/main/org/codehaus/groovy/classgen/AsmClassGenerator.java
+++ b/src/main/org/codehaus/groovy/classgen/AsmClassGenerator.java
@@ -1080,13 +1080,13 @@ public class AsmClassGenerator extends ClassGenerator {
         }
 
         if (fieldNode.isFinal()) {
-            throw new RuntimeParserException("Can not modify final field[" + 
fieldName + "] of " + classNode.getName() + "'s super class", expression);
+            throw new RuntimeParserException("Cannot modify final field[" + 
fieldName + "] of " + classNode.getName() + "'s super class", expression);
         }
 
         MethodNode setter = findSetter(classNode, fieldNode);
 
-        if (fieldNode.isPrivate() && null == setter) {
-            throw new RuntimeParserException("Can not access private field[" + 
fieldName + "] of " + classNode.getName() + "'s super class", expression);
+        if (Modifier.isPrivate(fieldNode.getModifiers()) && null == setter) {
+            throw new RuntimeParserException("Cannot access private field[" + 
fieldName + "] of " + classNode.getName() + "'s super class", expression);
         }
 
         mv.visitVarInsn(ALOAD, 0);

Reply via email to