Exemple #1
0
        protected override void SetArrayItemOverride(object key, object value)
        {
            IntStringKey  array_key;
            ScriptContext context = ScriptContext.CurrentContext;             // TODO: context -> field

            // extend and finish the setter chain if one already exists
            if (!Convert.ObjectToArrayKey(key, out array_key))
            {
                PhpException.IllegalOffsetType();
                context.AbortSetterChain(true);
                return;
            }

            context.ExtendSetterChain(new RuntimeChainItem(array_key));
            context.FinishSetterChain(value);
            return;
        }