clippy: Fix various clippy warnings throughout the code (#33003)

* replace u64::max_value() with u64::MAX

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* removed redundant import

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* Fixed dereference

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* Fixed a probable bug

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* fixed imports

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* fixed dereference

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* dereference formatting

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* removed unnessicary number imports

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* removed unnessicary number imports

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* removed excess borrow

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* ran mach fmt

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* fixed doc comment

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* removed deref on an immutable reference

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* fixed minor syntax error

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* reverted clamping

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* formatting

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

* reverted final clamp

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>

---------

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>
Co-authored-by: Ashwin Naren <ashwin@pixelators.org>
This commit is contained in:
Ashwin Naren 2024-08-12 22:16:47 -07:00 committed by GitHub
parent 0d137d276a
commit ea5cf75169
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
17 changed files with 25 additions and 29 deletions

View file

@ -72,7 +72,7 @@ impl Actor for AccessibilityActor {
/// - `getTraits`: Informs the DevTools client about the configuration of the accessibility actor
///
/// - `getWalker`: Returns a new AccessibleWalker actor (not to be confused with the general
/// inspector Walker actor)
/// inspector Walker actor)
fn handle_message(
&self,
registry: &ActorRegistry,

View file

@ -42,7 +42,7 @@ impl Actor for CssPropertiesActor {
/// The css properties actor can handle the following messages:
///
/// - `getCSSDatabase`: Returns a big list of every supported css property so that the
/// inspector can show the available options
/// inspector can show the available options
fn handle_message(
&self,
_registry: &ActorRegistry,

View file

@ -89,7 +89,7 @@ impl Actor for NodeActor {
/// The node actor can handle the following messages:
///
/// - `modifyAttributes`: Asks the script to change a value in the attribute of the
/// corresponding node
/// corresponding node
///
/// - `getUniqueSelector`: Returns the display name of this node
fn handle_message(

View file

@ -120,7 +120,7 @@ impl Actor for WalkerActor {
/// - `getOffsetParent`: Placeholder
///
/// - `querySelector`: Recursively looks for the specified selector in the tree, reutrning the
/// node and its ascendents
/// node and its ascendents
fn handle_message(
&self,
registry: &ActorRegistry,

View file

@ -77,7 +77,7 @@ impl Actor for TabDescriptorActor {
/// - `getFavicon`: Should return the tab favicon, but it is not yet supported.
///
/// - `getWatcher`: Returns a `WatcherActor` linked to the tab's `BrowsingContext`. It is used
/// to describe the debugging capabilities of this tab.
/// to describe the debugging capabilities of this tab.
fn handle_message(
&self,
registry: &ActorRegistry,

View file

@ -160,17 +160,17 @@ impl Actor for WatcherActor {
/// The watcher actor can handle the following messages:
///
/// - `watchTargets`: Returns a list of objects to debug. Since we only support web views, it
/// returns the associated `BrowsingContextActor`. Every target sent creates a
/// `target-available-form` event.
/// returns the associated `BrowsingContextActor`. Every target sent creates a
/// `target-available-form` event.
///
/// - `watchResources`: Start watching certain resource types. This sends
/// `resource-available-form` events.
/// `resource-available-form` events.
///
/// - `getNetworkParentActor`: Returns the network parent actor. It doesn't seem to do much at
/// the moment.
/// the moment.
///
/// - `getTargetConfigurationActor`: Returns the configuration actor for a specific target, so
/// that the server can update its settings.
/// that the server can update its settings.
///
/// - `getThreadConfigurationActor`: The same but with the configuration actor for the thread
fn handle_message(