Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Object.prototype.isPrototypeOf returns false for object literals #96

Closed
feimosi opened this issue Jan 29, 2016 · 6 comments
Closed

Object.prototype.isPrototypeOf returns false for object literals #96

feimosi opened this issue Jan 29, 2016 · 6 comments
Labels

Comments

@feimosi
Copy link

feimosi commented Jan 29, 2016

Not a big issue, but I've just noticed that:

a = {}
Object.prototype.isPrototypeOf(a) // returns false

and

a = new Object()
Object.prototype.isPrototypeOf(a) // returns true

Of course in both cases it should be true. I've checked that on Node and Chrome. Works good on both.
Mancy v2.2.0

@princejwesley
Copy link
Owner

@feimosi Issue is in script.runInContext function. node repl runs in global context(script.runInThisContext) and therefore, it works. I see few open issues reported in node repo. Its a v8 or node issue. node or v8 repo is a ideal place to raise this.
screen shot 2016-01-29 at 9 30 31 pm
screen shot 2016-01-29 at 9 30 19 pm

@princejwesley
Copy link
Owner

@feimosi I raised related issue few months ago. root cause sounds similar

@feimosi
Copy link
Author

feimosi commented Jan 29, 2016

@princejwesley Thanks for the quick response. You're right, it's a node related issue, let's wait for the fix then.

@feimosi feimosi changed the title Object.prototype.isPrototypeOf return false for object literals Object.prototype.isPrototypeOf returns false for object literals Feb 4, 2016
@princejwesley
Copy link
Owner

@feimosi Its not a node issue. I'll work on the fix.

@princejwesley
Copy link
Owner

image

@feimosi
Copy link
Author

feimosi commented Feb 6, 2016

Great, thanks for the fix! So we can consider this issue as resolved.

@feimosi feimosi closed this as completed Feb 6, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants