diff --git a/src/FESI/FESI.changes b/src/FESI/FESI.changes index 3332a08b..549b0193 100644 --- a/src/FESI/FESI.changes +++ b/src/FESI/FESI.changes @@ -15,3 +15,8 @@ Changes to standard FESI distribution (1.1.4) for Hop ESNumber. - Made EcmaScriptFunctionVisitor recognise thisObj - Functions are now assigned to the current thisObject. +- Added setPrototype() method to FESI.Data.ESObject to be able to manipulate + the prototype after the object was created. +- Changed FESI.Interpreter.EcmaScriptEvaluateVisitor to use .equals instead of + == in equal method for helma.framework.core.ESNode objects, since different + wrappers may wrap the same object. \ No newline at end of file diff --git a/src/FESI/Interpreter/EcmaScriptEvaluateVisitor.java b/src/FESI/Interpreter/EcmaScriptEvaluateVisitor.java index f9350cb7..2819e39e 100644 --- a/src/FESI/Interpreter/EcmaScriptEvaluateVisitor.java +++ b/src/FESI/Interpreter/EcmaScriptEvaluateVisitor.java @@ -248,6 +248,12 @@ public class EcmaScriptEvaluateVisitor return b1==b2; } + // ESNode wrappers must be checked with equals() because + // it's possible that different wrappers wrap the same node! + if (v1 instanceof helma.framework.core.ESNode) { + return v1.equals (v2); + } + return v1 == v2; }