Subj : Re: Sealing Scopes To : Miro From : Igor Bukanov Date : Fri Oct 08 2004 06:18 pm Miro wrote: > Igor Bukanov wrote in message news:<41666F9E.2070608@fastmail.fm>... > >>Context.newObjct(sharedScope) should not seal the created object. Are >>you sure that scope was sealed??? >> >>Regards, Igor > > > Scriptable scope = Context.newObjct(sharedScope) > > creates a copy of sharedScope. So if sharedScope was sealed, so is > scope. Context.newObjct(sharedScope) does not create any copies of sharedScope. It just calls new Object() using Object constructor stored in the sharedScope. That does not seal the result. > At least, it works that way on my enviroment... What is the result of ((ScriptableObject)scope).isSealed() after the call to Scriptable scope = Context.newObjct(sharedScope) ? Regards, Igor .