clippy: Allow too_many_arguments for existing functions (#31974)

* Allow `too_many_arguments` for existing functions

* fix: Surround ASCII with code block in rustdoc
This commit is contained in:
eri 2024-04-02 14:50:45 +02:00 committed by GitHub
parent f613159cba
commit cc082efbfd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
36 changed files with 86 additions and 64 deletions

View file

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this * 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/. */ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */
#![allow(clippy::too_many_arguments)]
use std::collections::{HashMap, HashSet}; use std::collections::{HashMap, HashSet};
use euclid::Size2D; use euclid::Size2D;
@ -81,6 +79,7 @@ pub struct BrowsingContext {
impl BrowsingContext { impl BrowsingContext {
/// Create a new browsing context. /// Create a new browsing context.
/// Note this just creates the browsing context, it doesn't add it to the constellation's set of browsing contexts. /// Note this just creates the browsing context, it doesn't add it to the constellation's set of browsing contexts.
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
bc_group_id: BrowsingContextGroupId, bc_group_id: BrowsingContextGroupId,
id: BrowsingContextId, id: BrowsingContextId,

View file

@ -84,8 +84,6 @@
//! //!
//! See <https://github.com/servo/servo/issues/14704> //! See <https://github.com/servo/servo/issues/14704>
#![allow(clippy::too_many_arguments)]
use std::borrow::{Cow, ToOwned}; use std::borrow::{Cow, ToOwned};
use std::collections::hash_map::Entry; use std::collections::hash_map::Entry;
use std::collections::{HashMap, HashSet, VecDeque}; use std::collections::{HashMap, HashSet, VecDeque};
@ -615,6 +613,7 @@ where
SWF: ServiceWorkerManagerFactory, SWF: ServiceWorkerManagerFactory,
{ {
/// Create a new constellation thread. /// Create a new constellation thread.
#[allow(clippy::too_many_arguments)]
pub fn start( pub fn start(
state: InitialConstellationState, state: InitialConstellationState,
layout_factory: Arc<dyn LayoutFactory>, layout_factory: Arc<dyn LayoutFactory>,
@ -941,6 +940,7 @@ where
} }
/// Helper function for creating a pipeline /// Helper function for creating a pipeline
#[allow(clippy::too_many_arguments)]
fn new_pipeline( fn new_pipeline(
&mut self, &mut self,
pipeline_id: PipelineId, pipeline_id: PipelineId,
@ -1126,6 +1126,7 @@ where
} }
/// Create a new browsing context and update the internal bookkeeping. /// Create a new browsing context and update the internal bookkeeping.
#[allow(clippy::too_many_arguments)]
fn new_browsing_context( fn new_browsing_context(
&mut self, &mut self,
browsing_context_id: BrowsingContextId, browsing_context_id: BrowsingContextId,

View file

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this * 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/. */ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */
#![allow(clippy::too_many_arguments)]
use std::borrow::Cow; use std::borrow::Cow;
use std::collections::{HashMap, HashSet}; use std::collections::{HashMap, HashSet};
use std::rc::Rc; use std::rc::Rc;
@ -349,6 +347,7 @@ impl Pipeline {
} }
/// Creates a new `Pipeline`, after the script has been spawned. /// Creates a new `Pipeline`, after the script has been spawned.
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
id: PipelineId, id: PipelineId,
browsing_context_id: BrowsingContextId, browsing_context_id: BrowsingContextId,

View file

@ -10,7 +10,6 @@
#![crate_name = "devtools"] #![crate_name = "devtools"]
#![crate_type = "rlib"] #![crate_type = "rlib"]
#![allow(non_snake_case)] #![allow(non_snake_case)]
#![allow(clippy::too_many_arguments)]
#![deny(unsafe_code)] #![deny(unsafe_code)]
use std::borrow::ToOwned; use std::borrow::ToOwned;
@ -420,6 +419,7 @@ fn run_server(
} }
} }
#[allow(clippy::too_many_arguments)]
fn handle_network_event( fn handle_network_event(
actors: Arc<Mutex<ActorRegistry>>, actors: Arc<Mutex<ActorRegistry>>,
mut connections: Vec<TcpStream>, mut connections: Vec<TcpStream>,

View file

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this * 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/. */ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */
#![allow(clippy::too_many_arguments)]
use app_units::Au; use app_units::Au;
use euclid::default::{Point2D, Rect, SideOffsets2D, Size2D}; use euclid::default::{Point2D, Rect, SideOffsets2D, Size2D};
use style::computed_values::background_attachment::single_value::T as BackgroundAttachment; use style::computed_values::background_attachment::single_value::T as BackgroundAttachment;
@ -145,6 +143,7 @@ pub fn clip(
/// no intrinsic size. /// no intrinsic size.
/// ///
/// Return `None` if the background size is zero, otherwise a [`BackgroundPlacement`]. /// Return `None` if the background size is zero, otherwise a [`BackgroundPlacement`].
#[allow(clippy::too_many_arguments)]
pub fn placement( pub fn placement(
bg: &Background, bg: &Background,
viewport_size: Size2D<Au>, viewport_size: Size2D<Au>,
@ -304,6 +303,7 @@ fn tile_image(position: &mut Au, size: &mut Au, absolute_anchor_origin: Au, imag
/// For either the x or the y axis adjust various values to account for tiling. /// For either the x or the y axis adjust various values to account for tiling.
/// ///
/// This is done separately for both axes because the repeat keywords may differ. /// This is done separately for both axes because the repeat keywords may differ.
#[allow(clippy::too_many_arguments)]
fn tile_image_axis( fn tile_image_axis(
repeat: BackgroundRepeatKeyword, repeat: BackgroundRepeatKeyword,
position: &mut Au, position: &mut Au,

View file

@ -8,8 +8,6 @@
//! list building, as the actual painting does not happen here—only deciding *what* we're going to //! list building, as the actual painting does not happen here—only deciding *what* we're going to
//! paint. //! paint.
#![allow(clippy::too_many_arguments)]
use std::default::Default; use std::default::Default;
use std::sync::Arc; use std::sync::Arc;
use std::{f32, mem}; use std::{f32, mem};
@ -1079,6 +1077,7 @@ impl Fragment {
/// Adds the display items necessary to paint the borders of this fragment to a display list if /// Adds the display items necessary to paint the borders of this fragment to a display list if
/// necessary. /// necessary.
#[allow(clippy::too_many_arguments)]
fn build_display_list_for_borders_if_applicable( fn build_display_list_for_borders_if_applicable(
&self, &self,
state: &mut DisplayListBuildState, state: &mut DisplayListBuildState,

View file

@ -12,8 +12,6 @@
//! They are therefore not exactly analogous to constructs like Skia pictures, which consist of //! They are therefore not exactly analogous to constructs like Skia pictures, which consist of
//! low-level drawing primitives. //! low-level drawing primitives.
#![allow(clippy::too_many_arguments)]
use std::cmp::Ordering; use std::cmp::Ordering;
use std::collections::HashMap; use std::collections::HashMap;
use std::{f32, fmt}; use std::{f32, fmt};
@ -206,6 +204,7 @@ pub struct StackingContext {
impl StackingContext { impl StackingContext {
/// Creates a new stacking context. /// Creates a new stacking context.
#[inline] #[inline]
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
id: StackingContextId, id: StackingContextId,
context_type: StackingContextType, context_type: StackingContextType,

View file

@ -4,8 +4,6 @@
//! CSS table formatting contexts. //! CSS table formatting contexts.
#![allow(clippy::too_many_arguments)]
use std::cmp::max; use std::cmp::max;
use std::fmt; use std::fmt;
use std::iter::{Enumerate, Peekable}; use std::iter::{Enumerate, Peekable};
@ -982,6 +980,7 @@ pub fn propagate_column_inline_sizes_to_child(
} }
/// Lay out table cells inline according to the computer column sizes. /// Lay out table cells inline according to the computer column sizes.
#[allow(clippy::too_many_arguments)]
fn set_inline_position_of_child_flow( fn set_inline_position_of_child_flow(
child_flow: &mut dyn Flow, child_flow: &mut dyn Flow,
child_index: usize, child_index: usize,

View file

@ -3,7 +3,6 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */
//! Text layout. //! Text layout.
#![allow(clippy::too_many_arguments)]
use std::borrow::ToOwned; use std::borrow::ToOwned;
use std::collections::LinkedList; use std::collections::LinkedList;
@ -705,6 +704,7 @@ impl RunMapping {
/// Flushes this run mapping to the list. `run_info` describes the text run that we're /// Flushes this run mapping to the list. `run_info` describes the text run that we're
/// currently working on. `text` refers to the text of this fragment. /// currently working on. `text` refers to the text of this fragment.
#[allow(clippy::too_many_arguments)]
fn flush( fn flush(
mut self, mut self,
mappings: &mut Vec<RunMapping>, mappings: &mut Vec<RunMapping>,

View file

@ -122,9 +122,9 @@ impl FileManager {
self.store.invalidate_token(token, file_id); self.store.invalidate_token(token, file_id);
} }
// Read a file for the Fetch implementation. /// Read a file for the Fetch implementation.
// It gets the required headers synchronously and reads the actual content /// It gets the required headers synchronously and reads the actual content
// in a separate thread. /// in a separate thread.
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
pub fn fetch_file( pub fn fetch_file(
&self, &self,

View file

@ -330,27 +330,28 @@ impl CanvasState {
pixels pixels
} }
// ///
// drawImage coordinates explained /// drawImage coordinates explained
// ///
// Source Image Destination Canvas /// ```
// +-------------+ +-------------+ /// Source Image Destination Canvas
// | | | | /// +-------------+ +-------------+
// |(sx,sy) | |(dx,dy) | /// | | | |
// | +----+ | | +----+ | /// |(sx,sy) | |(dx,dy) |
// | | | | | | | | /// | +----+ | | +----+ |
// | | |sh |---->| | |dh | /// | | | | | | | |
// | | | | | | | | /// | | |sh |---->| | |dh |
// | +----+ | | +----+ | /// | | | | | | | |
// | sw | | dw | /// | +----+ | | +----+ |
// | | | | /// | sw | | dw |
// +-------------+ +-------------+ /// | | | |
// /// +-------------+ +-------------+
// /// ```
// The rectangle (sx, sy, sw, sh) from the source image ///
// is copied on the rectangle (dx, dy, dh, dw) of the destination canvas /// The rectangle (sx, sy, sw, sh) from the source image
// /// is copied on the rectangle (dx, dy, dh, dw) of the destination canvas
// https://html.spec.whatwg.org/multipage/#dom-context-2d-drawimage ///
/// <https://html.spec.whatwg.org/multipage/#dom-context-2d-drawimage>
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
fn draw_image_internal( fn draw_image_internal(
&self, &self,
@ -594,10 +595,10 @@ impl CanvasState {
} }
} }
// It is used by DrawImage to calculate the size of the source and destination rectangles based /// It is used by DrawImage to calculate the size of the source and destination rectangles based
// on the drawImage call arguments /// on the drawImage call arguments
// source rectangle = area of the original image to be copied /// source rectangle = area of the original image to be copied
// destination rectangle = area of the destination canvas where the source image is going to be drawn /// destination rectangle = area of the destination canvas where the source image is going to be drawn
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
fn adjust_source_dest_rects( fn adjust_source_dest_rects(
&self, &self,
@ -844,7 +845,7 @@ impl CanvasState {
) )
} }
// https://html.spec.whatwg.org/multipage/#dom-context-2d-createradialgradient /// <https://html.spec.whatwg.org/multipage/#dom-context-2d-createradialgradient>
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
pub fn create_radial_gradient( pub fn create_radial_gradient(
&self, &self,
@ -1283,9 +1284,8 @@ impl CanvasState {
) )
} }
// https://html.spec.whatwg.org/multipage/#dom-context-2d-putimagedata /// <https://html.spec.whatwg.org/multipage/#dom-context-2d-putimagedata>
#[allow(unsafe_code)] #[allow(unsafe_code, clippy::too_many_arguments)]
#[allow(clippy::too_many_arguments)]
pub fn put_image_data_( pub fn put_image_data_(
&self, &self,
canvas_size: Size2D<u64>, canvas_size: Size2D<u64>,
@ -1381,7 +1381,7 @@ impl CanvasState {
) )
} }
// https://html.spec.whatwg.org/multipage/#dom-context-2d-drawimage /// <https://html.spec.whatwg.org/multipage/#dom-context-2d-drawimage>
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
pub fn draw_image__( pub fn draw_image__(
&self, &self,
@ -1653,7 +1653,7 @@ impl CanvasState {
Ok(()) Ok(())
} }
// https://html.spec.whatwg.org/multipage/#dom-context-2d-ellipse /// <https://html.spec.whatwg.org/multipage/#dom-context-2d-ellipse>
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
pub fn ellipse( pub fn ellipse(
&self, &self,

View file

@ -64,8 +64,7 @@ impl AudioParam {
} }
} }
#[allow(crown::unrooted_must_root)] #[allow(crown::unrooted_must_root, clippy::too_many_arguments)]
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
window: &Window, window: &Window,
context: &BaseAudioContext, context: &BaseAudioContext,

View file

@ -50,6 +50,7 @@ impl BluetoothAdvertisingEvent {
} }
} }
#[allow(clippy::too_many_arguments)]
fn new( fn new(
global: &GlobalScope, global: &GlobalScope,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -26,6 +26,7 @@ pub struct BluetoothCharacteristicProperties {
#[allow(non_snake_case)] #[allow(non_snake_case)]
impl BluetoothCharacteristicProperties { impl BluetoothCharacteristicProperties {
#[allow(clippy::too_many_arguments)]
pub fn new_inherited( pub fn new_inherited(
broadcast: bool, broadcast: bool,
read: bool, read: bool,
@ -51,6 +52,7 @@ impl BluetoothCharacteristicProperties {
} }
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
global: &GlobalScope, global: &GlobalScope,
broadcast: bool, broadcast: bool,

View file

@ -50,6 +50,7 @@ impl CloseEvent {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
global: &GlobalScope, global: &GlobalScope,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -48,6 +48,7 @@ impl CompositionEvent {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
window: &Window, window: &Window,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -237,6 +237,7 @@ impl WorkerEventLoopMethods for DedicatedWorkerGlobalScope {
} }
impl DedicatedWorkerGlobalScope { impl DedicatedWorkerGlobalScope {
#[allow(clippy::too_many_arguments)]
fn new_inherited( fn new_inherited(
init: WorkerGlobalScopeInit, init: WorkerGlobalScopeInit,
worker_name: DOMString, worker_name: DOMString,
@ -274,7 +275,7 @@ impl DedicatedWorkerGlobalScope {
} }
} }
#[allow(unsafe_code)] #[allow(unsafe_code, clippy::too_many_arguments)]
pub fn new( pub fn new(
init: WorkerGlobalScopeInit, init: WorkerGlobalScopeInit,
worker_name: DOMString, worker_name: DOMString,
@ -311,8 +312,8 @@ impl DedicatedWorkerGlobalScope {
unsafe { DedicatedWorkerGlobalScopeBinding::Wrap(SafeJSContext::from_ptr(cx), scope) } unsafe { DedicatedWorkerGlobalScopeBinding::Wrap(SafeJSContext::from_ptr(cx), scope) }
} }
#[allow(unsafe_code)] /// <https://html.spec.whatwg.org/multipage/#run-a-worker>
// https://html.spec.whatwg.org/multipage/#run-a-worker #[allow(unsafe_code, clippy::too_many_arguments)]
pub fn run_worker_scope( pub fn run_worker_scope(
mut init: WorkerGlobalScopeInit, mut init: WorkerGlobalScopeInit,
worker_url: ServoUrl, worker_url: ServoUrl,

View file

@ -3060,6 +3060,7 @@ pub enum HasBrowsingContext {
} }
impl Document { impl Document {
#[allow(clippy::too_many_arguments)]
pub fn new_inherited( pub fn new_inherited(
window: &Window, window: &Window,
has_browsing_context: HasBrowsingContext, has_browsing_context: HasBrowsingContext,
@ -3315,6 +3316,7 @@ impl Document {
)) ))
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
window: &Window, window: &Window,
has_browsing_context: HasBrowsingContext, has_browsing_context: HasBrowsingContext,
@ -3348,6 +3350,7 @@ impl Document {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
window: &Window, window: &Window,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -51,6 +51,7 @@ impl ErrorEvent {
reflect_dom_object_with_proto(Box::new(ErrorEvent::new_inherited()), global, proto) reflect_dom_object_with_proto(Box::new(ErrorEvent::new_inherited()), global, proto)
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
global: &GlobalScope, global: &GlobalScope,
type_: Atom, type_: Atom,
@ -67,6 +68,7 @@ impl ErrorEvent {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
global: &GlobalScope, global: &GlobalScope,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -64,6 +64,7 @@ impl ExtendableMessageEvent {
} }
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
global: &GlobalScope, global: &GlobalScope,
type_: Atom, type_: Atom,
@ -87,6 +88,7 @@ impl ExtendableMessageEvent {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
global: &GlobalScope, global: &GlobalScope,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -66,6 +66,7 @@ impl FocusEvent {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
window: &Window, window: &Window,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -52,6 +52,7 @@ pub struct Gamepad {
} }
impl Gamepad { impl Gamepad {
#[allow(clippy::too_many_arguments)]
fn new_inherited( fn new_inherited(
gamepad_id: u32, gamepad_id: u32,
id: String, id: String,

View file

@ -742,6 +742,7 @@ impl FileListener {
} }
impl GlobalScope { impl GlobalScope {
#[allow(clippy::too_many_arguments)]
pub fn new_inherited( pub fn new_inherited(
pipeline_id: PipelineId, pipeline_id: PipelineId,
devtools_chan: Option<IpcSender<ScriptToDevtoolsControlMsg>>, devtools_chan: Option<IpcSender<ScriptToDevtoolsControlMsg>>,

View file

@ -63,6 +63,7 @@ impl GPUAdapter {
} }
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
global: &GlobalScope, global: &GlobalScope,
channel: WebGPU, channel: WebGPU,

View file

@ -98,6 +98,7 @@ impl GPUBuffer {
} }
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
global: &GlobalScope, global: &GlobalScope,
channel: WebGPU, channel: WebGPU,

View file

@ -114,6 +114,7 @@ pub struct GPUDevice {
} }
impl GPUDevice { impl GPUDevice {
#[allow(clippy::too_many_arguments)]
fn new_inherited( fn new_inherited(
channel: WebGPU, channel: WebGPU,
adapter: &GPUAdapter, adapter: &GPUAdapter,
@ -144,6 +145,7 @@ impl GPUDevice {
} }
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
global: &GlobalScope, global: &GlobalScope,
channel: WebGPU, channel: WebGPU,

View file

@ -46,6 +46,7 @@ pub struct GPUTexture {
} }
impl GPUTexture { impl GPUTexture {
#[allow(clippy::too_many_arguments)]
fn new_inherited( fn new_inherited(
texture: WebGPUTexture, texture: WebGPUTexture,
device: &GPUDevice, device: &GPUDevice,
@ -74,6 +75,7 @@ impl GPUTexture {
} }
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
global: &GlobalScope, global: &GlobalScope,
texture: WebGPUTexture, texture: WebGPUTexture,

View file

@ -22,6 +22,7 @@ pub struct InputEvent {
} }
impl InputEvent { impl InputEvent {
#[allow(clippy::too_many_arguments)]
fn new( fn new(
window: &Window, window: &Window,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -64,6 +64,7 @@ impl KeyboardEvent {
reflect_dom_object_with_proto(Box::new(KeyboardEvent::new_inherited()), window, proto) reflect_dom_object_with_proto(Box::new(KeyboardEvent::new_inherited()), window, proto)
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
window: &Window, window: &Window,
type_: DOMString, type_: DOMString,
@ -99,6 +100,7 @@ impl KeyboardEvent {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
window: &Window, window: &Window,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -131,6 +131,7 @@ impl MessageEvent {
ev ev
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
global: &GlobalScope, global: &GlobalScope,
type_: Atom, type_: Atom,
@ -156,6 +157,7 @@ impl MessageEvent {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
global: &GlobalScope, global: &GlobalScope,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -85,6 +85,7 @@ impl MouseEvent {
reflect_dom_object_with_proto(Box::new(MouseEvent::new_inherited()), window, proto) reflect_dom_object_with_proto(Box::new(MouseEvent::new_inherited()), window, proto)
} }
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
window: &Window, window: &Window,
type_: DOMString, type_: DOMString,
@ -128,6 +129,7 @@ impl MouseEvent {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_with_proto( fn new_with_proto(
window: &Window, window: &Window,
proto: Option<HandleObject>, proto: Option<HandleObject>,

View file

@ -96,6 +96,7 @@ impl MutationRecord {
) )
} }
#[allow(clippy::too_many_arguments)]
fn new_inherited( fn new_inherited(
record_type: &str, record_type: &str,
target: &Node, target: &Node,

View file

@ -253,8 +253,7 @@ impl ServiceWorkerGlobalScope {
} }
} }
#[allow(unsafe_code)] #[allow(unsafe_code, clippy::too_many_arguments)]
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
init: WorkerGlobalScopeInit, init: WorkerGlobalScopeInit,
worker_url: ServoUrl, worker_url: ServoUrl,
@ -285,9 +284,8 @@ impl ServiceWorkerGlobalScope {
unsafe { ServiceWorkerGlobalScopeBinding::Wrap(SafeJSContext::from_ptr(cx), scope) } unsafe { ServiceWorkerGlobalScopeBinding::Wrap(SafeJSContext::from_ptr(cx), scope) }
} }
#[allow(unsafe_code)] /// <https://w3c.github.io/ServiceWorker/#run-service-worker-algorithm>
// https://w3c.github.io/ServiceWorker/#run-service-worker-algorithm #[allow(unsafe_code, clippy::too_many_arguments)]
#[allow(clippy::too_many_arguments)]
pub fn run_serviceworker_scope( pub fn run_serviceworker_scope(
scope_things: ScopeThings, scope_things: ScopeThings,
own_sender: Sender<ServiceWorkerScriptMsg>, own_sender: Sender<ServiceWorkerScriptMsg>,

View file

@ -453,8 +453,7 @@ impl WebGL2RenderingContext {
}) })
} }
#[allow(unsafe_code)] #[allow(unsafe_code, clippy::too_many_arguments)]
#[allow(clippy::too_many_arguments)]
fn read_pixels_into( fn read_pixels_into(
&self, &self,
x: i32, x: i32,

View file

@ -254,7 +254,7 @@ pub struct TexImage2DValidator<'a> {
} }
impl<'a> TexImage2DValidator<'a> { impl<'a> TexImage2DValidator<'a> {
// TODO: Move data validation logic here. /// TODO: Move data validation logic here.
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
context: &'a WebGLRenderingContext, context: &'a WebGLRenderingContext,

View file

@ -434,7 +434,7 @@ impl Handler {
Ok(()) Ok(())
} }
// https://w3c.github.io/webdriver/#dfn-perform-a-pointer-move /// <https://w3c.github.io/webdriver/#dfn-perform-a-pointer-move>
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
fn perform_pointer_move( fn perform_pointer_move(
&mut self, &mut self,