Re: [v8-users] IsFunction() on v8::Name returns false

2019-09-26 Thread Jakob Kummerow
In addition to what Simon said: from a V8 API point of view, we have a strict type system and class hierarchy (this is C++ after all, not JavaScript). A v8::Name is a name, not a function. For a v8::Local key, it will and must always be the case that key->IsName() returns true, and

Re: [v8-users] IsFunction() on v8::Name returns false

2019-09-26 Thread 'Simon Zünd' via v8-users
In terms of the JavaScript spec, you are performing a [[Set]] operation with `dict[x] = x`. The key for [[Set]] must be a valid property key, which is either a String or a Symbol. In this case, the code actually looks more like `dict[x.toString()] = x`. This is just how JavaScript works, and is

[v8-users] IsFunction() on v8::Name returns false

2019-09-26 Thread Gautham B A
Hi all, Calling IsFunction() on v8::Local is returning false, even though v8::Local was pointing to a function in JavaScript. Is this expected? Consider the following code - #include #include #include #include void Getter(v8::Local key, const v8::PropertyCallbackInfo ) {