On Sun, Feb 22, 2015 at 7:52 AM, Jeroen Ooms <jeroeno...@gmail.com> wrote:
> On Sat, Feb 21, 2015 at 10:41 PM, Ben Noordhuis <i...@bnoordhuis.nl> wrote:
>> Object.keys() only returns enumerable properties.
>> Object.getOwnPropertyNames() returns all properties.
>
> Thanks I was not aware of that. So that gives me a little bit more:
>
>> Object.getOwnPropertyNames(global)
> Math,ReferenceError,encodeURIComponent,Array,Number,escape,RegExp,unescape,ArrayBuffer,decodeURI,Error,NaN,Float32Array,isFinite,SyntaxError,Int16Array,parseInt,parseFloat,Float64Array,global,decodeURIComponent,EvalError,Uint32Array,Uint16Array,Int8Array,isNaN,TypeError,URIError,Date,eval,encodeURI,Object,print,Infinity,JSON,RangeError,undefined,console,Int32Array,DataView,String,Uint8Array,Function,Boolean
>
> Still a lot of the base language (true, false, for, break, etc) is
> missing. Should I just hardcode a list of JavaScript keywords for my
> tab-completer?

The io.js REPL partially evaluates the code in order to get accurate
auto-completion, see [0].  It works well although it's susceptible to
side-effects from getters.

[0] https://github.com/iojs/io.js/blob/97b4243/lib/repl.js#L422-684

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to