changeset 21943:1adad389c232

Truffle: remove Shape#copyOverPropertiesInternal
author Andreas Woess <andreas.woess@oracle.com>
date Tue, 16 Jun 2015 19:26:49 +0200
parents dd4050aadaf8
children 16725287d5af
files graal/com.oracle.truffle.api.object/src/com/oracle/truffle/api/object/Shape.java graal/com.oracle.truffle.object/src/com/oracle/truffle/object/ShapeImpl.java
diffstat 2 files changed, 0 insertions(+), 25 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.truffle.api.object/src/com/oracle/truffle/api/object/Shape.java	Tue Jun 16 13:43:32 2015 +0200
+++ b/graal/com.oracle.truffle.api.object/src/com/oracle/truffle/api/object/Shape.java	Tue Jun 16 19:26:49 2015 +0200
@@ -156,11 +156,6 @@
     public abstract Allocator allocator();
 
     /**
-     * For copying over properties after exchanging the prototype of an object.
-     */
-    public abstract Shape copyOverPropertiesInternal(Shape destination);
-
-    /**
      * Get number of properties in this shape.
      */
     public abstract int getPropertyCount();
--- a/graal/com.oracle.truffle.object/src/com/oracle/truffle/object/ShapeImpl.java	Tue Jun 16 13:43:32 2015 +0200
+++ b/graal/com.oracle.truffle.object/src/com/oracle/truffle/object/ShapeImpl.java	Tue Jun 16 19:26:49 2015 +0200
@@ -752,26 +752,6 @@
         return leftPtr;
     }
 
-    /**
-     * For copying over properties after exchanging the prototype of an object.
-     */
-    @TruffleBoundary
-    @Override
-    public final ShapeImpl copyOverPropertiesInternal(Shape destination) {
-        assert ((ShapeImpl) destination).getDepth() == 0;
-        List<Property> properties = this.getPropertyListInternal(true);
-        ShapeImpl newShape = ((ShapeImpl) destination).addPropertiesInternal(properties);
-        return newShape;
-    }
-
-    private ShapeImpl addPropertiesInternal(List<Property> properties) {
-        ShapeImpl newShape = this;
-        for (Property p : properties) {
-            newShape = newShape.addPropertyInternal(p);
-        }
-        return newShape;
-    }
-
     @Override
     public final int getPropertyCount() {
         return propertyCount;