8154445: JShell: Drop residual use of addReads from jshell
Reviewed-by: alanb, ksrini
--- a/langtools/src/jdk.jshell/share/classes/jdk/internal/jshell/remote/RemoteAgent.java Tue Apr 19 14:16:39 2016 +0200
+++ b/langtools/src/jdk.jshell/share/classes/jdk/internal/jshell/remote/RemoteAgent.java Wed Apr 20 08:30:30 2016 -0700
@@ -113,7 +113,6 @@
}
Method doitMethod;
try {
- this.getClass().getModule().addReads(klass.getModule());
this.getClass().getModule().addExports(RemoteResolutionException.class.getPackage().getName(), klass.getModule());
doitMethod = klass.getDeclaredMethod(DOIT_METHOD_NAME, new Class<?>[0]);
doitMethod.setAccessible(true);
@@ -184,7 +183,6 @@
break;
}
try {
- this.getClass().getModule().addReads(klass.getModule());
Field var = klass.getDeclaredField(varname);
var.setAccessible(true);
Object res = var.get(null);