public override void InitialiseBinding(ScriptValue name, ScriptValue value)
 {
     //https://tc39.github.io/ecma262/#sec-object-environment-records-initializebinding-n-v
     SetMutableBinding(name, value, false);
 }
 public override void CreateImmutableBinding(ScriptValue name, bool strict)
 {
     throw new NotImplementedException();
 }
 public override void CreateMutableBinding(ScriptValue name, bool deletable)
 {
     //https://tc39.github.io/ecma262/#sec-object-environment-records-createmutablebinding-n-d
     BindingObject.Agent.DefinePropertyOrThrow(BindingObject, name, new PropertyDescriptor(ScriptValue.Undefined, true, true, deletable));
 }
Example #4
0
 public override bool HasBinding(ScriptValue name)
 {
     return(declarativeRecord.HasBinding(name) || objectRecord.HasBinding(name));
 }
Example #5
0
 public PropertyDescriptor(ScriptValue value)
 {
     Value = value;
 }
 public override bool HasBinding(ScriptValue name)
 {
     return(bindings.ContainsKey(name));
 }