public object Copy() { if (GetType() == typeof(PythonDequeCollection)) { PythonDequeCollection res = new PythonDequeCollection(); res.Extend(this.GetEnumerator()); return(res); } else { UserType ut = Ops.GetDynamicType(this) as UserType; System.Diagnostics.Debug.Assert(ut != null); return(ut.Call(new object[] { GetEnumerator() })); } }