diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2019-04-23 15:24:33 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-23 15:24:33 -0400 |
commit | 4c8d29f5a7fb457cee3144b708c9e51142c2779a (patch) | |
tree | decf70ea4d949b44d4f555fa17c3544211ecdc74 /components/script | |
parent | 9a218e659a6404a56520e8416df3c2379fe34024 (diff) | |
parent | fea2ad0fabda22bd0651b2dbf2a603f333c26263 (diff) | |
download | servo-4c8d29f5a7fb457cee3144b708c9e51142c2779a.tar.gz servo-4c8d29f5a7fb457cee3144b708c9e51142c2779a.zip |
Auto merge of #23200 - krk:webidl-lint, r=jdm
Webidl lint
Parse webidl files and lint for inheritance correctness.
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #20461
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/23200)
<!-- Reviewable:end -->
Diffstat (limited to 'components/script')
-rw-r--r-- | components/script/Cargo.toml | 3 | ||||
-rw-r--r-- | components/script/dom/testbindingproxy.rs | 4 | ||||
-rw-r--r-- | components/script/dom/webidls/Window.webidl | 3 | ||||
-rw-r--r-- | components/script/dom/webidls/WindowProxy.webidl | 7 |
4 files changed, 11 insertions, 6 deletions
diff --git a/components/script/Cargo.toml b/components/script/Cargo.toml index 8076d77b7bb..c6dc04c6004 100644 --- a/components/script/Cargo.toml +++ b/components/script/Cargo.toml @@ -17,7 +17,8 @@ debugmozjs = ['js/debugmozjs'] profilemozjs = ['js/profilemozjs'] unstable = [] unrooted_must_root_lint = ["script_plugins/unrooted_must_root_lint"] -default = ["unrooted_must_root_lint"] +webidl_lint = ["script_plugins/webidl_lint"] +default = ["unrooted_must_root_lint", "webidl_lint"] webgl_backtrace = ["backtrace", "canvas_traits/webgl_backtrace"] js_backtrace = ["backtrace"] diff --git a/components/script/dom/testbindingproxy.rs b/components/script/dom/testbindingproxy.rs index 46134a3393f..3b352acb097 100644 --- a/components/script/dom/testbindingproxy.rs +++ b/components/script/dom/testbindingproxy.rs @@ -5,13 +5,13 @@ // check-tidy: no specs after this line use crate::dom::bindings::codegen::Bindings::TestBindingProxyBinding::TestBindingProxyMethods; -use crate::dom::bindings::reflector::Reflector; use crate::dom::bindings::str::DOMString; +use crate::dom::testbinding::TestBinding; use dom_struct::dom_struct; #[dom_struct] pub struct TestBindingProxy { - reflector_: Reflector, + testbinding_: TestBinding, } impl TestBindingProxyMethods for TestBindingProxy { diff --git a/components/script/dom/webidls/Window.webidl b/components/script/dom/webidls/Window.webidl index 1679fa42887..81ffee9283e 100644 --- a/components/script/dom/webidls/Window.webidl +++ b/components/script/dom/webidls/Window.webidl @@ -72,9 +72,6 @@ Window implements GlobalEventHandlers; Window implements WindowEventHandlers; -[NoInterfaceObject] -interface WindowProxy {}; - // https://html.spec.whatwg.org/multipage/#Window-partial partial interface Window { void captureEvents(); diff --git a/components/script/dom/webidls/WindowProxy.webidl b/components/script/dom/webidls/WindowProxy.webidl new file mode 100644 index 00000000000..897f86c295b --- /dev/null +++ b/components/script/dom/webidls/WindowProxy.webidl @@ -0,0 +1,7 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. */ + +// https://html.spec.whatwg.org/multipage/#the-windowproxy-exotic-object +[NoInterfaceObject] +interface WindowProxy {}; |