jasnell / proposal-istypes

TC-39 Proposal for additional is{Type} APIs
201 stars 7 forks source link

Clarification for `Symbol.isBuiltinDetectable` false behavior #19

Closed bengl closed 7 years ago

bengl commented 7 years ago

It looks obj[Symbol.isBuiltinDetectable] === false results in Bultins.typeof(obj) === typeof obj, but I can't find it explicitly mentioned anywhere.

jasnell commented 7 years ago

Yes, that is the case. If the value passed in to Builtins.typeof() is not detectable as a built-in, then it returns the value of typeof value. I can work on making that a bit clearer in the text.

jasnell commented 7 years ago

This has been since refactored...