Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rhino features beyond the ECMA standard?

I'm starting with JavaScript and the Rhino engine. I know the ECMAScript 262 specification. I need to know what features, e.g. functions/objects/etc are defined by the Rhino JavaScript engine beyond the ECMA standard. Most examples just feature print, Packages and import* but I wasn't able to find an exhaustive list.

like image 722
Peter Kofler Avatar asked Nov 29 '25 22:11

Peter Kofler


2 Answers

This isn't an exhaustive list but I have a compat table of non-standard ES features. Take a look at Rhino column — http://kangax.github.com/es5-compat-table/non-standard/.

Note how Rhino's feature set is pretty close to that of SpiderMonkey (latest JS engine in Firefox). There are differences though. For example, Rhino doesn't have "caller" property on functions, unlike SpiderMonkey. Rhino supports e4x but not expression closures. It looks more or less like a subset of SpiderMonkey, although there might be non-standard features that I'm not aware of (in which case I'd love to add them to the table).

like image 181
kangax Avatar answered Dec 01 '25 11:12

kangax


See predefined properties here: https://developer.mozilla.org/en/Rhino_Shell#Predefined_Properties

This is generally the best page about Rhino and it's JS features: https://developer.mozilla.org/en/Rhino_Shell

like image 44
oberhamsi Avatar answered Dec 01 '25 10:12

oberhamsi