changeset 22191:93a6b7597937

work around javac deprecation warning
author Andreas Woess <andreas.woess@oracle.com>
date Wed, 23 Sep 2015 23:55:03 +0200
parents 6050fb3fc842
children 1e753eabe503
files truffle/com.oracle.truffle.sl.tools/src/com/oracle/truffle/sl/tools/debug/SLREPLServer.java truffle/com.oracle.truffle.tools.debug.shell/src/com/oracle/truffle/tools/debug/shell/server/REPLServerContext.java
diffstat 2 files changed, 10 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/truffle/com.oracle.truffle.sl.tools/src/com/oracle/truffle/sl/tools/debug/SLREPLServer.java	Wed Sep 23 23:38:44 2015 +0200
+++ b/truffle/com.oracle.truffle.sl.tools/src/com/oracle/truffle/sl/tools/debug/SLREPLServer.java	Wed Sep 23 23:55:03 2015 +0200
@@ -215,9 +215,8 @@
         }
 
         @Override
-        @SuppressWarnings("deprecation")
-        public com.oracle.truffle.api.vm.TruffleVM vm() {
-            return (com.oracle.truffle.api.vm.TruffleVM) vm;
+        public PolyglotEngine engine() {
+            return vm;
         }
 
         @Override
--- a/truffle/com.oracle.truffle.tools.debug.shell/src/com/oracle/truffle/tools/debug/shell/server/REPLServerContext.java	Wed Sep 23 23:38:44 2015 +0200
+++ b/truffle/com.oracle.truffle.tools.debug.shell/src/com/oracle/truffle/tools/debug/shell/server/REPLServerContext.java	Wed Sep 23 23:55:03 2015 +0200
@@ -24,6 +24,10 @@
  */
 package com.oracle.truffle.tools.debug.shell.server;
 
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+
 import com.oracle.truffle.api.debug.Breakpoint;
 import com.oracle.truffle.api.debug.Debugger;
 import com.oracle.truffle.api.debug.SuspendedEvent;
@@ -35,9 +39,6 @@
 import com.oracle.truffle.api.vm.PolyglotEngine;
 import com.oracle.truffle.api.vm.PolyglotEngine.Language;
 import com.oracle.truffle.tools.debug.shell.REPLMessage;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
 
 public abstract class REPLServerContext {
 
@@ -85,7 +86,9 @@
      */
     @SuppressWarnings("deprecation")
     @Deprecated
-    public abstract com.oracle.truffle.api.vm.TruffleVM vm();
+    public com.oracle.truffle.api.vm.TruffleVM vm() {
+        return (com.oracle.truffle.api.vm.TruffleVM) engine();
+    }
 
     protected abstract Debugger db();
 
@@ -102,7 +105,7 @@
 
     /**
      * Provides access to the execution stack.
-     * 
+     *
      * @return immutable list of stack elements
      */
     public List<FrameDebugDescription> getStack() {