I was pondering about this on twitter, at first I thought using cycrllic variables to resolve references to object within the JSON object but actually we just need "this" to work within object literals and be allowed in the specification. For example this works currently : ({a:function(){ return this.b; },b:123}).a()
But it would be nicer to resolve "this" inside a object literal property to be itself rather than window or undefined: ({a:this,b:123}).a.b This would make JSON much smaller and allow circular references without losing data.
_______________________________________________ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss