Bug 109307

Summary: [Qt] Function.prototype.apply doesn't accept non-Array arguments list
Product: WebKit Reporter: Richard Gibson <richard.gibson>
Component: New BugsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED INVALID    
Severity: Normal CC: m.goleb+bugzilla
Priority: P3    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 110007    

Description Richard Gibson 2013-02-08 09:16:17 PST
Per spec at http://es5.github.com/#x15.3.4.3 , Function.prototype.apply should accept as its second argument any object with a length property (used as an exclusive upper bound on numeric "indices"). http://bugs.jquery.com/ticket/13282 implies that QtWebKit does not, because passing a NodeList (e.g., from document.getElementsByTagName("a")) fails (confirmed with phantomjs 1.7).

In other words, the following expressions should return [0, 1]:
  (function(a, b){ return [a, b]; }).apply( null, { length: 2, 0: 0, 1: 1 } )
Comment 1 Jocelyn Turcotte 2014-02-03 03:25:03 PST
=== Bulk closing of Qt bugs ===

If you believe that this bug report is still relevant for a non-Qt port of webkit.org, please re-open it and remove [Qt] from the summary.

If you believe that this is still an important QtWebKit bug, please fill a new report at https://bugreports.qt-project.org and add a link to this issue. See http://qt-project.org/wiki/ReportingBugsInQt for additional guidelines.