Subj : Re: [Rhino] can you add default getters/setters? To : netscape.public.mozilla.jseng From : Mike C. Date : Fri May 07 2004 09:19 am "Igor Bukanov" wrote > It is not possible in Rhino without parser modifications to support > Session("key") = "val"; > since in JS lvalue can only be either variable name or property > reference. Yes I have noticed that ;) Guess its in the ECMA standard. Same thing goes with the MS JScript: var obj = new Object; function test(key) { return obj["x_" + key]; } test("1") = 2; // can we assign to obj["x_1"] ? Gives an error: Microsoft JScript runtime error '800a138b' Cannot assign to a function result But Microsoft makes an exception for COM objects, so there goes one in my wishlist: can you make an exception for Java Objects, and move this error check from parsing to runtime introspection? Mike .