Bug 24716
| Summary: | typeof regexp returns function | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Peter Kim <raingrove> |
| Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | Normal | ||
| Priority: | P2 | ||
| Version: | 528+ (Nightly build) | ||
| Hardware: | Mac (Intel) | ||
| OS: | OS X 10.5 | ||
Peter Kim
typeof /someregexp/ returns 'function'.
expected value is 'regexp'
in firefox, 'object' is returned.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Peter Kim
looks like the consensus is that it should return 'object'
see discussion in mozilla bugzilla:
https://bugzilla.mozilla.org/show_bug.cgi?id=61911
Cameron Zwarich (cpst)
Ironically, this was originally done for compatibility with Mozilla. Bug 22082 suggests that we should change it back.
*** This bug has been marked as a duplicate of 22082 ***