Bug 481881 - [otdre] NPE when lifting finds a role but the role has been
gc'ed
- additional assumed corrections for add/removeRole()
diff --git a/org.eclipse.jdt.core/compiler/org/eclipse/objectteams/otdt/internal/core/compiler/bytecode/ConstantPoolObjectReader.java b/org.eclipse.jdt.core/compiler/org/eclipse/objectteams/otdt/internal/core/compiler/bytecode/ConstantPoolObjectReader.java
index e09bd8c..68e9851 100644
--- a/org.eclipse.jdt.core/compiler/org/eclipse/objectteams/otdt/internal/core/compiler/bytecode/ConstantPoolObjectReader.java
+++ b/org.eclipse.jdt.core/compiler/org/eclipse/objectteams/otdt/internal/core/compiler/bytecode/ConstantPoolObjectReader.java
@@ -503,7 +503,11 @@
if (CharOperation.prefixEquals(IOTConstants.OT_SETFIELD, name))
return AccPublic|AccStatic;
if (CharOperation.prefixEquals(IOTConstants.ADD_ROLE, name))
- return AccPublic|AccStatic;
+ return AccPublic;
+ if (CharOperation.prefixEquals(IOTConstants.REMOVE_ROLE, name))
+ return AccPublic;
+ if (CharOperation.prefixEquals(IOTConstants.ADD_REMOVE_ROLE, name))
+ return AccPublic;
// The next two are not searched in order to avoid receiver type o.o.Team.
// We want the tsub to always try to invoke its direct super, which may
// have more callin bindings than where known to the original dispatch method.