Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Update HTMLFormElement.length to be of type unsigned long
Fixes #9402
  • Loading branch information
Joshua Holmer committed Jan 22, 2016
1 parent 1c6fb0f commit 75d258f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions components/script/dom/htmlformelement.rs
Expand Up @@ -205,8 +205,8 @@ impl HTMLFormElementMethods for HTMLFormElement {
}

// https://html.spec.whatwg.org/multipage/#dom-form-length
fn Length(&self) -> i32 {
self.Elements().Length() as i32
fn Length(&self) -> u32 {
self.Elements().Length() as u32
}
}

Expand Down
2 changes: 1 addition & 1 deletion components/script/dom/webidls/HTMLFormElement.webidl
Expand Up @@ -17,7 +17,7 @@ interface HTMLFormElement : HTMLElement {
attribute DOMString target;

[SameObject] readonly attribute HTMLFormControlsCollection elements;
readonly attribute long length;
readonly attribute unsigned long length;
//getter Element (unsigned long index);
//getter (RadioNodeList or Element) (DOMString name);

Expand Down
2 changes: 1 addition & 1 deletion tests/wpt/web-platform-tests/html/dom/interfaces.html
Expand Up @@ -1591,7 +1591,7 @@ <h1>HTML IDL tests</h1>
attribute DOMString target;

readonly attribute HTMLFormControlsCollection elements;
readonly attribute long length;
readonly attribute unsigned long length;
getter Element (unsigned long index);
getter (RadioNodeList or Element) (DOMString name);

Expand Down

0 comments on commit 75d258f

Please sign in to comment.