cargo clippy #185
This workflow graph cannot be shown
A graph will be generated the next time this workflow is run.
Annotations
1 error and 402 warnings
Error
No event triggers defined in `on`
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/mod.rs#L100
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/mod.rs:100:5
|
100 | pub fn socket_to_peer(&self, socket_handle: &SocketHandle) -> Option<&PeerHandle> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn socket_to_peer(&self, socket_handle: &SocketHandle) -> Option<&PeerHandle>`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/mod.rs#L96
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/mod.rs:96:5
|
96 | pub fn peer_to_socket(&self, peer: &PeerHandle) -> Option<&SocketHandle> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn peer_to_socket(&self, peer: &PeerHandle) -> Option<&SocketHandle>`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/mod.rs#L79
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/mod.rs:79:5
|
79 | / pub fn insert_peer(
80 | | &mut self,
81 | | peer: PeerHandle,
82 | | socket_handle: SocketHandle,
83 | | ) -> Result<(), SocketMapError> {
| |___________________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/mod.rs#L73
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/mod.rs:73:5
|
73 | pub fn socket_to_channel_id(&self, socket_handle: &SocketHandle) -> Option<&ChannelId> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn socket_to_channel_id(&self, socket_handle: &SocketHandle) -> Option<&ChannelId>`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/mod.rs#L69
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/mod.rs:69:5
|
69 | pub fn channel_to_socket(&self, channel_id: &ChannelId) -> Option<&SocketHandle> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn channel_to_socket(&self, channel_id: &ChannelId) -> Option<&SocketHandle>`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/mod.rs#L52
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/mod.rs:52:5
|
52 | / pub fn insert_channel(
53 | | &mut self,
54 | | channel_id: ChannelId,
55 | | socket_handle: SocketHandle,
56 | | ) -> Result<(), SocketMapError> {
| |___________________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
this could be a `const fn`:
ublox-short-range/src/wifi/mod.rs#L45
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/mod.rs:45:5
|
45 | / fn new() -> Self {
46 | | Self {
47 | | channel_map: heapless::FnvIndexMap::new(),
48 | | peer_map: heapless::FnvIndexMap::new(),
49 | | }
50 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/wifi/tcp_stack.rs#L221
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/wifi/tcp_stack.rs:221:33
|
221 | ... ()
| ^^ help: add a `;` here: `();`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
|
unnecessary boolean `not` operation:
ublox-short-range/src/wifi/tcp_stack.rs#L213
warning: unnecessary boolean `not` operation
--> ublox-short-range/src/wifi/tcp_stack.rs:213:17
|
213 | / if !matches!(
214 | | tcp.state(),
215 | | TcpState::ShutdownForWrite(_) | TcpState::Created
216 | | ) {
... |
234 | | sockets.remove(socket)?;
235 | | }
| |_________________^
|
= help: remove the `!` and swap the blocks of the `if`/`else`
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#if_not_else
|
item in documentation is missing backticks:
ublox-short-range/src/wifi/tcp_stack.rs#L10
warning: item in documentation is missing backticks
--> ublox-short-range/src/wifi/tcp_stack.rs:10:32
|
10 | /// implements TCP and UDP for WiFi client
| ^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
10 | /// implements TCP and UDP for `WiFi` client
| ~~~~~~
|
usage of wildcard import:
ublox-short-range/src/wifi/tcp_stack.rs#L3
warning: usage of wildcard import
--> ublox-short-range/src/wifi/tcp_stack.rs:3:5
|
3 | command::data_mode::*,
| ^^^^^^^^^^^^^^^^^^^^^ help: try: `command::data_mode::{ClosePeerConnection, ConnectPeer}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
item in documentation is missing backticks:
ublox-short-range/src/wifi/udp_stack.rs#L293
warning: item in documentation is missing backticks
--> ublox-short-range/src/wifi/udp_stack.rs:293:30
|
293 | /// - The driver has to call send_to after reciving data, to release the socket bound by remote host,
| ^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
293 | /// - The driver has to call `send_to` after reciving data, to release the socket bound by remote host,
| ~~~~~~~~~
|
item in documentation is missing backticks:
ublox-short-range/src/wifi/udp_stack.rs#L292
warning: item in documentation is missing backticks
--> ublox-short-range/src/wifi/udp_stack.rs:292:32
|
292 | /// - The driver can only call send_to once after reciving data once.
| ^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
292 | /// - The driver can only call `send_to` once after reciving data once.
| ~~~~~~~~~
|
usage of wildcard import:
ublox-short-range/src/wifi/udp_stack.rs#L3
warning: usage of wildcard import
--> ublox-short-range/src/wifi/udp_stack.rs:3:5
|
3 | command::data_mode::*,
| ^^^^^^^^^^^^^^^^^^^^^ help: try: `command::data_mode::{ClosePeerConnection, ConnectPeer, ServerConfiguration}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
variables can be used directly in the `format!` string:
ublox-short-range/src/wifi/peer_builder.rs#L72
warning: variables can be used directly in the `format!` string
--> ublox-short-range/src/wifi/peer_builder.rs:72:26
|
72 | .map(|v| write!(&mut s, "privKey={}&", v).ok());
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
|
72 - .map(|v| write!(&mut s, "privKey={}&", v).ok());
72 + .map(|v| write!(&mut s, "privKey={v}&").ok());
|
|
variables can be used directly in the `format!` string:
ublox-short-range/src/wifi/peer_builder.rs#L68
warning: variables can be used directly in the `format!` string
--> ublox-short-range/src/wifi/peer_builder.rs:68:26
|
68 | .map(|v| write!(&mut s, "cert={}&", v).ok());
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
|
68 - .map(|v| write!(&mut s, "cert={}&", v).ok());
68 + .map(|v| write!(&mut s, "cert={v}&").ok());
|
|
variables can be used directly in the `format!` string:
ublox-short-range/src/wifi/peer_builder.rs#L64
warning: variables can be used directly in the `format!` string
--> ublox-short-range/src/wifi/peer_builder.rs:64:26
|
64 | .map(|v| write!(&mut s, "ca={}&", v).ok());
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
|
64 - .map(|v| write!(&mut s, "ca={}&", v).ok());
64 + .map(|v| write!(&mut s, "ca={v}&").ok());
|
|
variables can be used directly in the `format!` string:
ublox-short-range/src/wifi/peer_builder.rs#L58
warning: variables can be used directly in the `format!` string
--> ublox-short-range/src/wifi/peer_builder.rs:58:22
|
58 | .map(|v| write!(&mut s, "local_port={}&", v).ok());
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
|
58 - .map(|v| write!(&mut s, "local_port={}&", v).ok());
58 + .map(|v| write!(&mut s, "local_port={v}&").ok());
|
|
variables can be used directly in the `format!` string:
ublox-short-range/src/wifi/peer_builder.rs#L43
warning: variables can be used directly in the `format!` string
--> ublox-short-range/src/wifi/peer_builder.rs:43:22
|
43 | .map(|v| write!(&mut s, "local_port={}&", v).ok());
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
|
43 - .map(|v| write!(&mut s, "local_port={}&", v).ok());
43 + .map(|v| write!(&mut s, "local_port={v}&").ok());
|
|
variables can be used directly in the `format!` string:
ublox-short-range/src/wifi/peer_builder.rs#L30
warning: variables can be used directly in the `format!` string
--> ublox-short-range/src/wifi/peer_builder.rs:30:30
|
30 | .and_then(|host| write!(s, "{}:{}/", host, port).ok());
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
= note: `-W clippy::uninlined-format-args` implied by `-W clippy::pedantic`
help: change this to
|
30 - .and_then(|host| write!(s, "{}:{}/", host, port).ok());
30 + .and_then(|host| write!(s, "{host}:{port}/").ok());
|
|
item in documentation is missing backticks:
ublox-short-range/src/wifi/peer_builder.rs#L4
warning: item in documentation is missing backticks
--> ublox-short-range/src/wifi/peer_builder.rs:4:32
|
4 | /// implements TCP and UDP for WiFi client
| ^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
4 | /// implements TCP and UDP for `WiFi` client
| ~~~~~~
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/tls.rs#L13
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/tls.rs:13:5
|
13 | / fn import_private_key(
14 | | &mut self,
15 | | name: &str,
16 | | private_key: &[u8],
17 | | password: Option<&str>,
18 | | ) -> Result<(), Error>;
| |___________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/tls.rs#L12
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/tls.rs:12:5
|
12 | fn import_root_ca(&mut self, name: &str, root_ca: &[u8]) -> Result<(), Error>;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/tls.rs#L11
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/tls.rs:11:5
|
11 | fn import_certificate(&mut self, name: &str, certificate: &[u8]) -> Result<(), Error>;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
usage of wildcard import:
ublox-short-range/src/wifi/tls.rs#L3
warning: usage of wildcard import
--> ublox-short-range/src/wifi/tls.rs:3:35
|
3 | command::security::{types::*, *},
| ^ help: try: `PrepareSecurityDataImport, SendSecurityDataImport`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/wifi/tls.rs#L3
warning: usage of wildcard import
--> ublox-short-range/src/wifi/tls.rs:3:25
|
3 | command::security::{types::*, *},
| ^^^^^^^^ help: try: `types::SecurityDataType`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L567
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:567:5
|
567 | pub fn unset_active_on_startup(&mut self) -> Result<(), WifiConnectionError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L516
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:516:5
|
516 | pub fn set_active_on_startup(&mut self, config_id: u8) -> Result<(), WifiConnectionError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/supplicant.rs#L509
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/supplicant.rs:509:5
|
509 | pub fn has_active_on_startup(&self) -> bool {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn has_active_on_startup(&self) -> bool`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/supplicant.rs#L500
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/supplicant.rs:500:5
|
500 | pub fn get_active_on_startup(&self) -> Option<u8> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn get_active_on_startup(&self) -> Option<u8>`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L495
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:495:5
|
495 | pub fn flush(&mut self) -> Result<(), WifiConnectionError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function which may panic missing `# Panics` section:
ublox-short-range/src/wifi/supplicant.rs#L495
warning: docs for function which may panic missing `# Panics` section
--> ublox-short-range/src/wifi/supplicant.rs:495:5
|
495 | pub fn flush(&mut self) -> Result<(), WifiConnectionError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
note: first possible panic found here
--> ublox-short-range/src/wifi/supplicant.rs:496:9
|
496 | todo!()
| ^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_panics_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L477
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:477:5
|
477 | pub fn scan(&mut self) -> Result<Vec<WifiNetwork, 32>, WifiError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L453
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:453:5
|
453 | pub fn deactivate(&mut self, config_id: u8) -> Result<(), WifiConnectionError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L412
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:412:5
|
412 | pub fn activate(&mut self, config_id: u8) -> Result<(), WifiConnectionError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L307
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:307:5
|
307 | / pub fn insert_connection(
308 | | &mut self,
309 | | config_id: u8,
310 | | options: &ConnectionOptions,
311 | | ) -> Result<(), WifiConnectionError> {
| |________________________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L277
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:277:5
|
277 | pub fn remove_connection(&mut self, config_id: u8) -> Result<(), WifiConnectionError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
casting `usize` to `u8` may truncate the value:
ublox-short-range/src/wifi/supplicant.rs#L265
warning: casting `usize` to `u8` may truncate the value
--> ublox-short-range/src/wifi/supplicant.rs:265:16
|
265 | Ok((0..N as u8)
| ^^^^^^^
|
= help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
help: ... or use `try_from` and handle the error accordingly
|
265 | Ok((0..u8::try_from(N))
| ~~~~~~~~~~~~~~~
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L263
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:263:5
|
263 | pub fn list_connections(&mut self) -> Result<Vec<(u8, ConnectionOptions), N>, Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function which may panic missing `# Panics` section:
ublox-short-range/src/wifi/supplicant.rs#L263
warning: docs for function which may panic missing `# Panics` section
--> ublox-short-range/src/wifi/supplicant.rs:263:5
|
263 | pub fn list_connections(&mut self) -> Result<Vec<(u8, ConnectionOptions), N>, Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
note: first possible panic found here
--> ublox-short-range/src/wifi/supplicant.rs:267:17
|
267 | / self.get_connection(config_id)
268 | | .unwrap()
| |_____________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_panics_doc
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/supplicant.rs#L251
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/supplicant.rs:251:5
|
251 | pub fn has_active_config_id(&self) -> bool {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn has_active_config_id(&self) -> bool`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/supplicant.rs#L239
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/supplicant.rs:239:5
|
239 | pub fn get_active_config_id(&self) -> Option<u8> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn get_active_config_id(&self) -> Option<u8>`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
this pattern matching can be expressed using equality:
ublox-short-range/src/wifi/supplicant.rs#L203
warning: this pattern matching can be expressed using equality
--> ublox-short-range/src/wifi/supplicant.rs:203:12
|
203 | if let WifiStationConfigR::IPv4Mode(IPv4Mode::Static) = ip_mode {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `ip_mode == WifiStationConfigR::IPv4Mode(IPv4Mode::Static)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#equatable_if_let
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/supplicant.rs#L161
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/supplicant.rs:161:5
|
161 | pub fn get_connection(&mut self, config_id: u8) -> Result<Option<ConnectionOptions>, Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
casting `usize` to `u8` may truncate the value:
ublox-short-range/src/wifi/supplicant.rs#L85
warning: casting `usize` to `u8` may truncate the value
--> ublox-short-range/src/wifi/supplicant.rs:85:29
|
85 | for config_id in 0..N as u8 {
| ^^^^^^^
|
= help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
help: ... or use `try_from` and handle the error accordingly
|
85 | for config_id in 0..u8::try_from(N) {
| ~~~~~~~~~~~~~~~
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/wifi/options.rs#L129
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/wifi/options.rs:129:19
|
129 | self.ip = if let Some(ip) = self.ip {
| ___________________^
130 | | Some(ip)
131 | | } else {
132 | | Some(Ipv4Addr::new(192, 168, 2, 1))
133 | | };
| |_________^ help: try: `self.ip.map_or_else(|| Some(Ipv4Addr::new(192, 168, 2, 1)), |ip| Some(ip))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/wifi/options.rs#L123
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/wifi/options.rs:123:23
|
123 | self.subnet = if let Some(subnet) = self.subnet {
| _______________________^
124 | | Some(subnet)
125 | | } else {
126 | | Some(Ipv4Addr::new(255, 255, 255, 0))
127 | | };
| |_________^ help: try: `self.subnet.map_or_else(|| Some(Ipv4Addr::new(255, 255, 255, 0)), |subnet| Some(subnet))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/wifi/options.rs#L120
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/wifi/options.rs:120:5
|
120 | / pub fn gateway_address(mut self, gateway_addr: Ipv4Addr) -> Self {
121 | | self.gateway = Some(gateway_addr);
122 | |
123 | | self.subnet = if let Some(subnet) = self.subnet {
... |
134 | | self
135 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
this could be a `const fn`:
ublox-short-range/src/wifi/options.rs#L120
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/options.rs:120:5
|
120 | / pub fn gateway_address(mut self, gateway_addr: Ipv4Addr) -> Self {
121 | | self.gateway = Some(gateway_addr);
122 | |
123 | | self.subnet = if let Some(subnet) = self.subnet {
... |
134 | | self
135 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L120
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:120:5
|
120 | pub fn gateway_address(mut self, gateway_addr: Ipv4Addr) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn gateway_address(mut self, gateway_addr: Ipv4Addr) -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/wifi/options.rs#L111
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/wifi/options.rs:111:24
|
111 | self.gateway = if let Some(gateway) = self.gateway {
| ________________________^
112 | | Some(gateway)
113 | | } else {
114 | | Some(Ipv4Addr::new(192, 168, 2, 1))
115 | | };
| |_________^ help: try: `self.gateway.map_or_else(|| Some(Ipv4Addr::new(192, 168, 2, 1)), |gateway| Some(gateway))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/wifi/options.rs#L105
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/wifi/options.rs:105:19
|
105 | self.ip = if let Some(ip) = self.ip {
| ___________________^
106 | | Some(ip)
107 | | } else {
108 | | Some(Ipv4Addr::new(192, 168, 2, 1))
109 | | };
| |_________^ help: try: `self.ip.map_or_else(|| Some(Ipv4Addr::new(192, 168, 2, 1)), |ip| Some(ip))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/wifi/options.rs#L102
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/wifi/options.rs:102:5
|
102 | / pub fn subnet_address(mut self, subnet_addr: Ipv4Addr) -> Self {
103 | | self.subnet = Some(subnet_addr);
104 | |
105 | | self.ip = if let Some(ip) = self.ip {
... |
117 | | self
118 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
this could be a `const fn`:
ublox-short-range/src/wifi/options.rs#L102
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/options.rs:102:5
|
102 | / pub fn subnet_address(mut self, subnet_addr: Ipv4Addr) -> Self {
103 | | self.subnet = Some(subnet_addr);
104 | |
105 | | self.ip = if let Some(ip) = self.ip {
... |
117 | | self
118 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L102
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:102:5
|
102 | pub fn subnet_address(mut self, subnet_addr: Ipv4Addr) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn subnet_address(mut self, subnet_addr: Ipv4Addr) -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/wifi/options.rs#L94
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/wifi/options.rs:94:24
|
94 | self.gateway = if let Some(gateway) = self.gateway {
| ________________________^
95 | | Some(gateway)
96 | | } else {
97 | | Some(Ipv4Addr::new(192, 168, 2, 1))
98 | | };
| |_________^ help: try: `self.gateway.map_or_else(|| Some(Ipv4Addr::new(192, 168, 2, 1)), |gateway| Some(gateway))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/wifi/options.rs#L88
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/wifi/options.rs:88:23
|
88 | self.subnet = if let Some(subnet) = self.subnet {
| _______________________^
89 | | Some(subnet)
90 | | } else {
91 | | Some(Ipv4Addr::new(255, 255, 255, 0))
92 | | };
| |_________^ help: try: `self.subnet.map_or_else(|| Some(Ipv4Addr::new(255, 255, 255, 0)), |subnet| Some(subnet))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/wifi/options.rs#L86
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/wifi/options.rs:86:5
|
86 | / pub fn ip_address(mut self, ip_addr: Ipv4Addr) -> Self {
87 | | self.ip = Some(ip_addr);
88 | | self.subnet = if let Some(subnet) = self.subnet {
89 | | Some(subnet)
... |
99 | | self
100 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
this could be a `const fn`:
ublox-short-range/src/wifi/options.rs#L86
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/options.rs:86:5
|
86 | / pub fn ip_address(mut self, ip_addr: Ipv4Addr) -> Self {
87 | | self.ip = Some(ip_addr);
88 | | self.subnet = if let Some(subnet) = self.subnet {
89 | | Some(subnet)
... |
99 | | self
100 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L86
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:86:5
|
86 | pub fn ip_address(mut self, ip_addr: Ipv4Addr) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn ip_address(mut self, ip_addr: Ipv4Addr) -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/wifi/options.rs#L81
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/wifi/options.rs:81:5
|
81 | / pub fn password(mut self, password: String<64>) -> Self {
82 | | self.password = Some(password);
83 | | self
84 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
this could be a `const fn`:
ublox-short-range/src/wifi/options.rs#L81
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/options.rs:81:5
|
81 | / pub fn password(mut self, password: String<64>) -> Self {
82 | | self.password = Some(password);
83 | | self
84 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L81
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:81:5
|
81 | pub fn password(mut self, password: String<64>) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn password(mut self, password: String<64>) -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/wifi/options.rs#L76
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/wifi/options.rs:76:5
|
76 | / pub fn ssid(mut self, ssid: String<64>) -> Self {
77 | | self.ssid = ssid;
78 | | self
79 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
this could be a `const fn`:
ublox-short-range/src/wifi/options.rs#L76
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/options.rs:76:5
|
76 | / pub fn ssid(mut self, ssid: String<64>) -> Self {
77 | | self.ssid = ssid;
78 | | self
79 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L76
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:76:5
|
76 | pub fn ssid(mut self, ssid: String<64>) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn ssid(mut self, ssid: String<64>) -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L72
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:72:5
|
72 | pub fn new() -> Self {
| ^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn new() -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
item name ends with its containing module's name:
ublox-short-range/src/wifi/options.rs#L59
warning: item name ends with its containing module's name
--> ublox-short-range/src/wifi/options.rs:59:12
|
59 | pub struct ConnectionOptions {
| ^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/wifi/options.rs#L52
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/wifi/options.rs:52:5
|
52 | / pub fn band(mut self, band: Band) -> Self {
53 | | self.band = Some(band);
54 | | self
55 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
this could be a `const fn`:
ublox-short-range/src/wifi/options.rs#L52
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/options.rs:52:5
|
52 | / pub fn band(mut self, band: Band) -> Self {
53 | | self.band = Some(band);
54 | | self
55 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L52
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:52:5
|
52 | pub fn band(mut self, band: Band) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn band(mut self, band: Band) -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/wifi/options.rs#L47
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/wifi/options.rs:47:5
|
47 | / pub fn channel(mut self, channel: Channel) -> Self {
48 | | self.channel = Some(channel);
49 | | self
50 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
this could be a `const fn`:
ublox-short-range/src/wifi/options.rs#L47
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/options.rs:47:5
|
47 | / pub fn channel(mut self, channel: Channel) -> Self {
48 | | self.channel = Some(channel);
49 | | self
50 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L47
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:47:5
|
47 | pub fn channel(mut self, channel: Channel) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn channel(mut self, channel: Channel) -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
this could be a `const fn`:
ublox-short-range/src/wifi/options.rs#L40
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/options.rs:40:5
|
40 | / pub fn new() -> Self {
41 | | Self {
42 | | channel: Some(Channel::One),
43 | | band: Some(Band::Bg),
44 | | }
45 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/options.rs#L40
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/options.rs:40:5
|
40 | pub fn new() -> Self {
| ^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn new() -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
item name ends with its containing module's name:
ublox-short-range/src/wifi/options.rs#L34
warning: item name ends with its containing module's name
--> ublox-short-range/src/wifi/options.rs:34:12
|
34 | pub struct HotspotOptions {
| ^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
unnecessary structure name repetition:
ublox-short-range/src/wifi/network.rs#L32
warning: unnecessary structure name repetition
--> ublox-short-range/src/wifi/network.rs:32:12
|
32 | Ok(WifiNetwork {
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
item name ends with its containing module's name:
ublox-short-range/src/wifi/network.rs#L16
warning: item name ends with its containing module's name
--> ublox-short-range/src/wifi/network.rs:16:12
|
16 | pub struct WifiNetwork {
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/wifi/network.rs#L9
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/wifi/network.rs:9:10
|
9 | #[derive(PartialEq, Debug)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
this pattern matching can be expressed using equality:
ublox-short-range/src/wifi/dns.rs#L42
warning: this pattern matching can be expressed using equality
--> ublox-short-range/src/wifi/dns.rs:42:15
|
42 | while let Some(DNSState::Resolving) = self.dns_table.get_state(String::from(hostname)) {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `self.dns_table.get_state(String::from(hostname)) == Some(DNSState::Resolving)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#equatable_if_let
= note: `-W clippy::equatable-if-let` implied by `-W clippy::nursery`
|
usage of wildcard import:
ublox-short-range/src/wifi/dns.rs#L7
warning: usage of wildcard import
--> ublox-short-range/src/wifi/dns.rs:7:13
|
7 | use crate::{command::ping::*, UbloxClient};
| ^^^^^^^^^^^^^^^^ help: try: `command::ping::{Ping, types}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
this could be a `const fn`:
ublox-short-range/src/wifi/connection.rs#L55
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/connection.rs:55:5
|
55 | / pub(crate) fn activate(mut self) -> Self {
56 | | self.activated = true;
57 | | self
58 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/connection.rs#L51
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/connection.rs:51:5
|
51 | pub fn is_access_point(&self) -> bool {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn is_access_point(&self) -> bool`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/wifi/connection.rs#L47
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/wifi/connection.rs:47:5
|
47 | pub fn is_station(&self) -> bool {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn is_station(&self) -> bool`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
unnecessary structure name repetition:
ublox-short-range/src/wifi/connection.rs#L34
warning: unnecessary structure name repetition
--> ublox-short-range/src/wifi/connection.rs:34:9
|
34 | WifiConnection {
| ^^^^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
this could be a `const fn`:
ublox-short-range/src/wifi/connection.rs#L33
warning: this could be a `const fn`
--> ublox-short-range/src/wifi/connection.rs:33:5
|
33 | / pub(crate) fn new(network: WifiNetwork, wifi_state: WiFiState, config_id: u8) -> Self {
34 | | WifiConnection {
35 | | wifi_state,
36 | | network_state: NetworkState::Unattached,
... |
40 | | }
41 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
item name ends with its containing module's name:
ublox-short-range/src/wifi/connection.rs#L21
warning: item name ends with its containing module's name
--> ublox-short-range/src/wifi/connection.rs:21:12
|
21 | pub struct WifiConnection {
| ^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/wifi/connection.rs#L13
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/wifi/connection.rs:13:30
|
13 | #[derive(Debug, Clone, Copy, PartialEq, defmt::Format)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/wifi/connection.rs#L3
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/wifi/connection.rs:3:30
|
3 | #[derive(Debug, Clone, Copy, PartialEq, defmt::Format)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/wifi/ap.rs#L224
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/wifi/ap.rs:224:13
|
224 | con.deactivate()
| ^^^^^^^^^^^^^^^^ help: add a `;` here: `con.deactivate();`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/ap.rs#L207
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/ap.rs:207:5
|
207 | pub fn stop_hotspot(&mut self) -> Result<(), WifiHotspotError> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
this argument is passed by value, but not consumed in the function body:
ublox-short-range/src/wifi/ap.rs#L37
warning: this argument is passed by value, but not consumed in the function body
--> ublox-short-range/src/wifi/ap.rs:37:24
|
37 | configuration: HotspotOptions,
| ^^^^^^^^^^^^^^ help: consider taking a reference instead: `&HotspotOptions`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
|
this function has too many lines (135/100):
ublox-short-range/src/wifi/ap.rs#L34
warning: this function has too many lines (135/100)
--> ublox-short-range/src/wifi/ap.rs:34:5
|
34 | / pub fn create_hotspot(
35 | | &mut self,
36 | | options: ConnectionOptions,
37 | | configuration: HotspotOptions,
... |
201 | | Ok(())
202 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/wifi/ap.rs#L34
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/wifi/ap.rs:34:5
|
34 | / pub fn create_hotspot(
35 | | &mut self,
36 | | options: ConnectionOptions,
37 | | configuration: HotspotOptions,
38 | | ) -> Result<(), WifiHotspotError> {
| |_____________________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L140
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:140:9
|
140 | WifiError::ATError(error)
| ^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L132
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:132:9
|
132 | WifiConnectionError::Other {
| ^^^^^^^^^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L126
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:126:9
|
126 | WifiConnectionError::Other { kind: error }
| ^^^^^^^^^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L118
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:118:9
|
118 | WifiHotspotError::Other {
| ^^^^^^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L112
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:112:9
|
112 | WifiHotspotError::Other { kind: error }
| ^^^^^^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L106
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:106:9
|
106 | WifiHotspotError::Internal(e)
| ^^^^^^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
item name ends with its containing module's name:
ublox-short-range/src/error.rs#L91
warning: item name ends with its containing module's name
--> ublox-short-range/src/error.rs:91:10
|
91 | pub enum WifiHotspotError {
| ^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
item name ends with its containing module's name:
ublox-short-range/src/error.rs#L75
warning: item name ends with its containing module's name
--> ublox-short-range/src/error.rs:75:10
|
75 | pub enum WifiError {
| ^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L70
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:70:9
|
70 | WifiConnectionError::Internal(e)
| ^^^^^^^^^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
item name ends with its containing module's name:
ublox-short-range/src/error.rs#L49
warning: item name ends with its containing module's name
--> ublox-short-range/src/error.rs:49:10
|
49 | pub enum WifiConnectionError {
| ^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L43
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:43:9
|
43 | Error::Socket(e)
| ^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/error.rs#L37
warning: unnecessary structure name repetition
--> ublox-short-range/src/error.rs:37:9
|
37 | Error::AT(e)
| ^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
item name ends with its containing module's name:
ublox-short-range/src/error.rs#L1
warning: item name ends with its containing module's name
--> ublox-short-range/src/error.rs:1:33
|
1 | pub use ublox_sockets::Error as SocketError;
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
unnecessary structure name repetition:
ublox-short-range/src/config.rs#L99
warning: unnecessary structure name repetition
--> ublox-short-range/src/config.rs:99:9
|
99 | Config {
| ^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/config.rs#L97
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/config.rs:97:5
|
97 | / pub fn tls_out_buffer_size(self, bytes: u16) -> Self {
98 | | assert!(bytes > 512);
99 | | Config {
100 | | tls_out_buffer_size: Some(bytes),
101 | | ..self
102 | | }
103 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
docs for function which may panic missing `# Panics` section:
ublox-short-range/src/config.rs#L97
warning: docs for function which may panic missing `# Panics` section
--> ublox-short-range/src/config.rs:97:5
|
97 | pub fn tls_out_buffer_size(self, bytes: u16) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
note: first possible panic found here
--> ublox-short-range/src/config.rs:98:9
|
98 | assert!(bytes > 512);
| ^^^^^^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_panics_doc
|
item in documentation is missing backticks:
ublox-short-range/src/config.rs#L96
warning: item in documentation is missing backticks
--> ublox-short-range/src/config.rs:96:9
|
96 | /// DEFAULT_TLS_OUT_BUFFER_SIZE (3072)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
96 | /// `DEFAULT_TLS_OUT_BUFFER_SIZE` (3072)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
unnecessary structure name repetition:
ublox-short-range/src/config.rs#L86
warning: unnecessary structure name repetition
--> ublox-short-range/src/config.rs:86:9
|
86 | Config {
| ^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/config.rs#L84
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/config.rs:84:5
|
84 | / pub fn tls_in_buffer_size(self, bytes: u16) -> Self {
85 | | assert!(bytes > 512);
86 | | Config {
87 | | tls_in_buffer_size: Some(bytes),
88 | | ..self
89 | | }
90 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
docs for function which may panic missing `# Panics` section:
ublox-short-range/src/config.rs#L84
warning: docs for function which may panic missing `# Panics` section
--> ublox-short-range/src/config.rs:84:5
|
84 | pub fn tls_in_buffer_size(self, bytes: u16) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
note: first possible panic found here
--> ublox-short-range/src/config.rs:85:9
|
85 | assert!(bytes > 512);
| ^^^^^^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_panics_doc
= note: `-W clippy::missing-panics-doc` implied by `-W clippy::pedantic`
|
item in documentation is missing backticks:
ublox-short-range/src/config.rs#L83
warning: item in documentation is missing backticks
--> ublox-short-range/src/config.rs:83:9
|
83 | /// DEFAULT_TLS_IN_BUFFER_SIZE (7800)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
83 | /// `DEFAULT_TLS_IN_BUFFER_SIZE` (7800)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
unnecessary structure name repetition:
ublox-short-range/src/config.rs#L73
warning: unnecessary structure name repetition
--> ublox-short-range/src/config.rs:73:9
|
73 | Config {
| ^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/config.rs#L72
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/config.rs:72:5
|
72 | / pub fn max_urc_attempts(self, max_attempts: u8) -> Self {
73 | | Config {
74 | | max_urc_attempts: max_attempts,
75 | | ..self
76 | | }
77 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
this could be a `const fn`:
ublox-short-range/src/config.rs#L72
warning: this could be a `const fn`
--> ublox-short-range/src/config.rs:72:5
|
72 | / pub fn max_urc_attempts(self, max_attempts: u8) -> Self {
73 | | Config {
74 | | max_urc_attempts: max_attempts,
75 | | ..self
76 | | }
77 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
unnecessary structure name repetition:
ublox-short-range/src/config.rs#L66
warning: unnecessary structure name repetition
--> ublox-short-range/src/config.rs:66:9
|
66 | Config {
| ^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/config.rs#L65
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/config.rs:65:5
|
65 | / pub fn with_hostname(self, hostname: &str) -> Self {
66 | | Config {
67 | | hostname: Some(String::from(hostname)),
68 | | ..self
69 | | }
70 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
|
unnecessary structure name repetition:
ublox-short-range/src/config.rs#L59
warning: unnecessary structure name repetition
--> ublox-short-range/src/config.rs:59:9
|
59 | Config {
| ^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
missing `#[must_use]` attribute on a method returning `Self`:
ublox-short-range/src/config.rs#L58
warning: missing `#[must_use]` attribute on a method returning `Self`
--> ublox-short-range/src/config.rs:58:5
|
58 | / pub fn with_rst(self, rst_pin: RST) -> Self {
59 | | Config {
60 | | rst_pin: Some(rst_pin),
61 | | ..self
62 | | }
63 | | }
| |_____^
|
= help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use
= note: `-W clippy::return-self-not-must-use` implied by `-W clippy::pedantic`
|
this could be a `const fn`:
ublox-short-range/src/config.rs#L58
warning: this could be a `const fn`
--> ublox-short-range/src/config.rs:58:5
|
58 | / pub fn with_rst(self, rst_pin: RST) -> Self {
59 | | Config {
60 | | rst_pin: Some(rst_pin),
61 | | ..self
62 | | }
63 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
unnecessary structure name repetition:
ublox-short-range/src/config.rs#L48
warning: unnecessary structure name repetition
--> ublox-short-range/src/config.rs:48:9
|
48 | Config {
| ^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
this could be a `const fn`:
ublox-short-range/src/config.rs#L47
warning: this could be a `const fn`
--> ublox-short-range/src/config.rs:47:5
|
47 | / pub fn new() -> Self {
48 | | Config {
49 | | rst_pin: None,
50 | | hostname: None,
... |
55 | | }
56 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/config.rs#L47
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/config.rs:47:5
|
47 | pub fn new() -> Self {
| ^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn new() -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
|
unnecessary structure name repetition:
ublox-short-range/src/config.rs#L32
warning: unnecessary structure name repetition
--> ublox-short-range/src/config.rs:32:9
|
32 | Config {
| ^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
you seem to be trying to match on a boolean expression:
ublox-short-range/src/command/mod.rs#L102
warning: you seem to be trying to match on a boolean expression
--> ublox-short-range/src/command/mod.rs:102:9
|
102 | / match b {
103 | | true => Self::On,
104 | | false => Self::Off,
105 | | }
| |_________^ help: consider using an `if`/`else` expression: `if b { Self::On } else { Self::Off }`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_bool
= note: `-W clippy::match-bool` implied by `-W clippy::pedantic`
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/mod.rs#L93
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/mod.rs:93:17
|
93 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/mod.rs#L19
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/mod.rs:19:34
|
19 | #[derive(Debug, Clone, AtatResp, PartialEq)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
item name starts with its containing module's name:
ublox-short-range/src/command/wifi/mod.rs#L185
warning: item name starts with its containing module's name
--> ublox-short-range/src/command/wifi/mod.rs:185:12
|
185 | pub struct WifiAPStatus {
| ^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
item name starts with its containing module's name:
ublox-short-range/src/command/wifi/mod.rs#L173
warning: item name starts with its containing module's name
--> ublox-short-range/src/command/wifi/mod.rs:173:12
|
173 | pub struct WifiAPAction {
| ^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
item name starts with its containing module's name:
ublox-short-range/src/command/wifi/mod.rs#L63
warning: item name starts with its containing module's name
--> ublox-short-range/src/command/wifi/mod.rs:63:12
|
63 | pub struct WifiScan<'a> {
| ^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
usage of wildcard import:
ublox-short-range/src/command/wifi/mod.rs#L9
warning: usage of wildcard import
--> ublox-short-range/src/command/wifi/mod.rs:9:5
|
9 | use types::*;
| ^^^^^^^^ help: try: `types::{AccessPointAction, AccessPointConfig, AccessPointConfigParameter, AccessPointId, AccessPointStatusId, StatusId, WatchdogSetting, WifiConfig, WifiConfigParameter, WifiStationAction, WifiStationConfig, WifiStationConfigParameter}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/wifi/mod.rs#L8
warning: usage of wildcard import
--> ublox-short-range/src/command/wifi/mod.rs:8:5
|
8 | use responses::*;
| ^^^^^^^^^^^^ help: try: `responses::{GetWifiStationConfigResponse, WiFiAPStationListResponse, WifiAPConfigResponse, WifiAPStatusResponse, WifiConfigResponse, WifiMacResponse, WifiScanResponse, WifiStatusResponse}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/urc.rs#L53
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/urc.rs:53:17
|
53 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/urc.rs#L44
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/urc.rs:44:17
|
44 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/urc.rs#L37
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/urc.rs:37:17
|
37 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/urc.rs#L30
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/urc.rs:30:17
|
30 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/urc.rs#L7
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/urc.rs:7:17
|
7 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/wifi/urc.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/wifi/urc.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::DisconnectReason`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
item in documentation is missing backticks:
ublox-short-range/src/command/wifi/urc.rs#L1
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/wifi/urc.rs:1:31
|
1 | //! Unsolicited responses for WiFi Commands
| ^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
1 | //! Unsolicited responses for `WiFi` Commands
| ~~~~~~
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1409
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1409:24
|
1409 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1403
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1403:17
|
1403 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1369
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1369:17
|
1369 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1349
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1349:17
|
1349 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1343
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1343:17
|
1343 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1335
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1335:17
|
1335 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1324
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1324:17
|
1324 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1318
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1318:17
|
1318 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1312
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1312:17
|
1312 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1305
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1305:17
|
1305 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1296
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1296:17
|
1296 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L1021
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:1021:17
|
1021 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L865
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:865:23
|
865 | #[derive(Clone, Copy, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L859
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:859:17
|
859 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L851
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:851:17
|
851 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L843
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:843:17
|
843 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L831
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:831:17
|
831 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L822
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:822:17
|
822 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L814
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:814:17
|
814 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L531
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:531:17
|
531 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L521
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:521:17
|
521 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L513
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:513:17
|
513 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L436
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:436:17
|
436 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L429
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:429:24
|
429 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L409
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:409:17
|
409 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L399
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:399:17
|
399 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/wifi/types.rs#L10
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/wifi/types.rs:10:17
|
10 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
item in documentation is missing backticks:
ublox-short-range/src/command/wifi/types.rs#L1
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/wifi/types.rs:1:42
|
1 | //! Argument and parameter types used by WiFi Commands and Responses
| ^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
1 | //! Argument and parameter types used by `WiFi` Commands and Responses
| ~~~~~~
|
usage of wildcard import:
ublox-short-range/src/command/wifi/responses.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/wifi/responses.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::{AccessPointConfigResponse, AccessPointId, AccessPointStatus, ScannedWifiNetwork, WifiConfig, WifiStationConfigR, WifiStatus}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
item in documentation is missing backticks:
ublox-short-range/src/command/wifi/responses.rs#L1
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/wifi/responses.rs:1:19
|
1 | //! Responses for WiFi Commands
| ^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
1 | //! Responses for `WiFi` Commands
| ~~~~~~
|
item in documentation is missing backticks:
ublox-short-range/src/command/wifi/mod.rs#L1
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/wifi/mod.rs:1:14
|
1 | //! ### 20 - WiFi Commands
| ^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
1 | //! ### 20 - `WiFi` Commands
| ~~~~~~
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L264
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:264:17
|
264 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/mod.rs#L239
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/mod.rs:239:54
|
239 | /// Enable routing of radio signals to EXT_TX_EN and EXT_RX_EN pins.
| ^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
239 | /// Enable routing of radio signals to EXT_TX_EN and `EXT_RX_EN` pins.
| ~~~~~~~~~~~
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/mod.rs#L239
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/mod.rs:239:40
|
239 | /// Enable routing of radio signals to EXT_TX_EN and EXT_RX_EN pins.
| ^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
239 | /// Enable routing of radio signals to `EXT_TX_EN` and EXT_RX_EN pins.
| ~~~~~~~~~~~
|
item name starts with its containing module's name:
ublox-short-range/src/command/system/mod.rs#L203
warning: item name starts with its containing module's name
--> ublox-short-range/src/command/system/mod.rs:203:12
|
203 | pub struct SystemStatus {
| ^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/mod.rs#L199
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/mod.rs:199:45
|
199 | /// Reads current status of the system. If <status_id> is omitted, all applicable ids will be
| ^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
199 | /// Reads current status of the system. If <`status_id`> is omitted, all applicable ids will be
| ~~~~~~~~~~~
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L156
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:156:17
|
156 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L130
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:130:17
|
130 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L117
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:117:17
|
117 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L101
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:101:17
|
101 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L80
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:80:17
|
80 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/mod.rs#L63
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/mod.rs:63:39
|
63 | /// from the DTE in Command Mode. If <echo_on> is omitted, it turns off the echoing.
| ^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
63 | /// from the DTE in Command Mode. If <`echo_on`> is omitted, it turns off the echoing.
| ~~~~~~~~~
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/mod.rs#L51
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/mod.rs:51:12
|
51 | /// signal UART_DTR) states.
| ^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
51 | /// signal `UART_DTR`) states.
| ~~~~~~~~~~
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/mod.rs#L50
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/mod.rs:50:43
|
50 | /// between ASSERTED (logical 0 on signal UART_DTR) and DEASSERTED (logical 1 on
| ^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
50 | /// between ASSERTED (logical 0 on signal `UART_DTR`) and DEASSERTED (logical 1 on
| ~~~~~~~~~~
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/mod.rs#L38
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/mod.rs:38:19
|
38 | /// (logical 1 on UART_DSR signal) states.
| ^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
38 | /// (logical 1 on `UART_DSR` signal) states.
| ~~~~~~~~~~
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/mod.rs#L37
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/mod.rs:37:44
|
37 | /// changes between ASSERTED (logical 0 on UART_DSR signal) and DEASSERTED
| ^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
37 | /// changes between ASSERTED (logical 0 on `UART_DSR` signal) and DEASSERTED
| ~~~~~~~~~~
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L30
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:30:17
|
30 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L23
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:23:17
|
23 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/mod.rs#L15
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/mod.rs:15:17
|
15 | #[derive(Debug, PartialEq, Clone, AtatCmd)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/system/mod.rs#L7
warning: usage of wildcard import
--> ublox-short-range/src/command/system/mod.rs:7:5
|
7 | use types::*;
| ^^^^^^^^ help: try: `types::{BaudRate, ChangeAfterConfirm, DSRAssertMode, DTRMode, EchoOn, FlowControl, InserfaceID, Mode, ModuleStartMode, Parity, PowerRegulatorSettings, SoftwareUpdateBaudRate, SoftwareUpdateMode, StatusID, StopBits}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/system/mod.rs#L6
warning: usage of wildcard import
--> ublox-short-range/src/command/system/mod.rs:6:5
|
6 | use responses::*;
| ^^^^^^^^^^^^ help: try: `responses::{LPODetectionResponse, LocalAddressResponse, SoftwareUpdateResponse, SystemStatusResponse}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L175
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:175:24
|
175 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L166
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:166:24
|
166 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L153
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:153:24
|
153 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
item in documentation is missing backticks:
ublox-short-range/src/command/system/types.rs#L155
warning: item in documentation is missing backticks
--> ublox-short-range/src/command/system/types.rs:155:51
|
155 | /// When operating in the extended data mode, the change_after_confirm has no
| ^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
155 | /// When operating in the extended data mode, the `change_after_confirm` has no
| ~~~~~~~~~~~~~~~~~~~~~~
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L142
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:142:24
|
142 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L133
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:133:24
|
133 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L124
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:124:24
|
124 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L101
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:101:24
|
101 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L90
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:90:24
|
90 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L82
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:82:24
|
82 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L72
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:72:24
|
72 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L63
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:63:24
|
63 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L56
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:56:24
|
56 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L47
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:47:24
|
47 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L31
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:31:24
|
31 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L15
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:15:24
|
15 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/types.rs#L5
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/types.rs:5:24
|
5 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/responses.rs#L15
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/responses.rs:15:17
|
15 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/system/responses.rs#L7
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/system/responses.rs:7:17
|
7 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/system/responses.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/system/responses.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::{LPODetection, StatusID}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/security/mod.rs#L8
warning: usage of wildcard import
--> ublox-short-range/src/command/security/mod.rs:8:5
|
8 | use types::*;
| ^^^^^^^^ help: try: `types::SecurityDataType`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/security/mod.rs#L7
warning: usage of wildcard import
--> ublox-short-range/src/command/security/mod.rs:7:5
|
7 | use responses::*;
| ^^^^^^^^^^^^ help: try: `responses::{ImportResponse, SecurityDataImport, SecurityDataMD5}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/security/types.rs#L18
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/security/types.rs:18:17
|
18 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/security/types.rs#L5
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/security/types.rs:5:17
|
5 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/security/responses.rs#L7
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/security/responses.rs:7:17
|
7 | #[derive(Clone, PartialEq, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/security/responses.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/security/responses.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::{SecurityDataType, SecurityOperation}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ping/urc.rs#L25
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ping/urc.rs:25:17
|
25 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/ping/urc.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/ping/urc.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::PingError`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ping/types.rs#L28
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ping/types.rs:28:17
|
28 | #[derive(Debug, PartialEq, Clone, Copy, AtatEnum, defmt::Format)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/network/mod.rs#L8
warning: usage of wildcard import
--> ublox-short-range/src/command/network/mod.rs:8:5
|
8 | use types::*;
| ^^^^^^^^ help: try: `types::{BridgeAction, BridgeConfig, BridgeConfigId, NetworkStatusParameter, RoutingTag, Timing}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/network/mod.rs#L7
warning: usage of wildcard import
--> ublox-short-range/src/command/network/mod.rs:7:5
|
7 | use responses::*;
| ^^^^^^^^^^^^ help: try: `responses::NetworkStatusResponse`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/urc.rs#L13
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/urc.rs:13:17
|
13 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/urc.rs#L6
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/urc.rs:6:17
|
6 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/network/urc.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/network/urc.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::ErrorType`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L270
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:270:24
|
270 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L245
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:245:17
|
245 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L223
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:223:17
|
223 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L216
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:216:17
|
216 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L142
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:142:17
|
142 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L136
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:136:17
|
136 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L123
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:123:17
|
123 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L111
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:111:17
|
111 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/network/types.rs#L66
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/network/types.rs:66:17
|
66 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/network/responses.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/network/responses.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::{NetworkIpv6Status, NetworkStatus}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/gpio/mod.rs#L7
warning: usage of wildcard import
--> ublox-short-range/src/command/gpio/mod.rs:7:5
|
7 | use types::*;
| ^^^^^^^^ help: try: `types::{GPIOId, GPIOMode, GPIOValue}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/gpio/mod.rs#L6
warning: usage of wildcard import
--> ublox-short-range/src/command/gpio/mod.rs:6:5
|
6 | use responses::*;
| ^^^^^^^^^^^^ help: try: `responses::ReadGPIOResponse`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/gpio/types.rs#L86
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/gpio/types.rs:86:17
|
86 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/gpio/types.rs#L74
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/gpio/types.rs:74:17
|
74 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/gpio/types.rs#L66
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/gpio/types.rs:66:17
|
66 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/gpio/types.rs#L4
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/gpio/types.rs:4:17
|
4 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/gpio/responses.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/gpio/responses.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::{GPIOId, GPIOValue}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/general/mod.rs#L7
warning: usage of wildcard import
--> ublox-short-range/src/command/general/mod.rs:7:5
|
7 | use types::*;
| ^^^^^^^^ help: try: `types::GreetingTextMode`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/general/mod.rs#L6
warning: usage of wildcard import
--> ublox-short-range/src/command/general/mod.rs:6:5
|
6 | use responses::*;
| ^^^^^^^^^^^^ help: try: `responses::{IdentificationInfomationMCUIDResponse, IdentificationInfomationSoftwareVersionResponse, IdentificationInfomationTypeCodeResponse, ManufacturerIdentificationResponse, ModelIdentificationResponse, SerialNumberResponse, SoftwareVersionResponse}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/command/general/types.rs#L111
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/command/general/types.rs:111:13
|
111 | defmt::write!(fmt, "{}.{}.{}", self.major, self.minor, self.patch,)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add a `;` here: `defmt::write!(fmt, "{}.{}.{}", self.major, self.minor, self.patch,);`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/command/general/types.rs#L109
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/command/general/types.rs:109:13
|
109 | defmt::write!(fmt, "{}.{}.{}-{}", self.major, self.minor, self.patch, meta)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add a `;` here: `defmt::write!(fmt, "{}.{}.{}-{}", self.major, self.minor, self.patch, meta);`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/command/general/types.rs#L108
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/command/general/types.rs:108:9
|
108 | / if let Some(meta) = &self.meta {
109 | | defmt::write!(fmt, "{}.{}.{}-{}", self.major, self.minor, self.patch, meta)
110 | | } else {
111 | | defmt::write!(fmt, "{}.{}.{}", self.major, self.minor, self.patch,)
112 | | }
| |_________^ help: try: `self.meta.as_ref().map_or_else(|| defmt::write!(fmt, "{}.{}.{}", self.major, self.minor, self.patch,), |meta| defmt::write!(fmt, "{}.{}.{}-{}", self.major, self.minor, self.patch, meta))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
|
this could be a `const fn`:
ublox-short-range/src/command/general/types.rs#L39
warning: this could be a `const fn`
--> ublox-short-range/src/command/general/types.rs:39:5
|
39 | / pub fn new(major: u8, minor: u8, patch: u8) -> Self {
40 | | Self {
41 | | major,
42 | | minor,
... |
45 | | }
46 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
this method could have a `#[must_use]` attribute:
ublox-short-range/src/command/general/types.rs#L39
warning: this method could have a `#[must_use]` attribute
--> ublox-short-range/src/command/general/types.rs:39:5
|
39 | pub fn new(major: u8, minor: u8, patch: u8) -> Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn new(major: u8, minor: u8, patch: u8) -> Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
= note: `-W clippy::must-use-candidate` implied by `-W clippy::pedantic`
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/general/types.rs#L19
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/general/types.rs:19:17
|
19 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/general/types.rs#L8
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/general/types.rs:8:17
|
8 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/general/responses.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/general/responses.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::FirmwareVersion`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
item name starts with its containing module's name:
ublox-short-range/src/command/ethernet/mod.rs#L43
warning: item name starts with its containing module's name
--> ublox-short-range/src/command/ethernet/mod.rs:43:12
|
43 | pub struct EthernetConfigurationAction {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
usage of wildcard import:
ublox-short-range/src/command/ethernet/mod.rs#L8
warning: usage of wildcard import
--> ublox-short-range/src/command/ethernet/mod.rs:8:5
|
8 | use types::*;
| ^^^^^^^^ help: try: `types::{EthernetConfig, EthernetConfigAction, EthernetConfigParameter}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/ethernet/mod.rs#L7
warning: usage of wildcard import
--> ublox-short-range/src/command/ethernet/mod.rs:7:5
|
7 | use responses::*;
| ^^^^^^^^^^^^ help: try: `responses::EthernetConfigurationResponse`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ethernet/urc.rs#L9
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ethernet/urc.rs:9:17
|
9 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ethernet/urc.rs#L5
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ethernet/urc.rs:5:17
|
5 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ethernet/types.rs#L212
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ethernet/types.rs:212:17
|
212 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ethernet/types.rs#L205
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ethernet/types.rs:205:17
|
205 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ethernet/types.rs#L198
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ethernet/types.rs:198:17
|
198 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ethernet/types.rs#L191
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ethernet/types.rs:191:17
|
191 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/ethernet/types.rs#L8
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/ethernet/types.rs:8:17
|
8 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/ethernet/responses.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/ethernet/responses.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::EthernetConfigR`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
used `cloned` where `copied` could be used instead:
ublox-short-range/src/command/edm/mod.rs#L208
warning: used `cloned` where `copied` could be used instead
--> ublox-short-range/src/command/edm/mod.rs:208:10
|
208 | .cloned()
| ^^^^^^ help: try: `copied`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cloned_instead_of_copied
|
item name starts with its containing module's name:
ublox-short-range/src/command/edm/mod.rs#L193
warning: item name starts with its containing module's name
--> ublox-short-range/src/command/edm/mod.rs:193:12
|
193 | pub struct EdmResendConnectEventsCommand;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
used `cloned` where `copied` could be used instead:
ublox-short-range/src/command/edm/mod.rs#L179
warning: used `cloned` where `copied` could be used instead
--> ublox-short-range/src/command/edm/mod.rs:179:33
|
179 | .chain(self.data.iter().cloned())
| ^^^^^^ help: try: `copied`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cloned_instead_of_copied
|
used `cloned` where `copied` could be used instead:
ublox-short-range/src/command/edm/mod.rs#L178
warning: used `cloned` where `copied` could be used instead
--> ublox-short-range/src/command/edm/mod.rs:178:10
|
178 | .cloned()
| ^^^^^^ help: try: `copied`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cloned_instead_of_copied
|
casting `usize` to `u16` may truncate the value:
ublox-short-range/src/command/edm/mod.rs#L168
warning: casting `usize` to `u16` may truncate the value
--> ublox-short-range/src/command/edm/mod.rs:168:27
|
168 | let payload_len = (self.data.len() + 3) as u16;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
help: ... or use `try_from` and handle the error accordingly
|
168 | let payload_len = u16::try_from(self.data.len() + 3);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
item name starts with its containing module's name:
ublox-short-range/src/command/edm/mod.rs#L157
warning: item name starts with its containing module's name
--> ublox-short-range/src/command/edm/mod.rs:157:12
|
157 | pub struct EdmDataCommand<'a> {
| ^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/command/edm/mod.rs#L139
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/command/edm/mod.rs:139:13
|
139 | / match resp
140 | | .windows(b"\r\nOK".len())
141 | | .position(|window| window == b"\r\nOK")
142 | | {
... |
147 | | None => Ok(&resp[AT_COMMAND_POSITION..PAYLOAD_POSITION + payload_len]),
148 | | }
| |_____________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
help: try
|
139 ~ resp
140 + .windows(b"\r\nOK".len())
141 + .position(|window| window == b"\r\nOK").map_or_else(|| Ok(&resp[AT_COMMAND_POSITION..PAYLOAD_POSITION + payload_len]), |pos| Ok(&resp[AT_COMMAND_POSITION..pos]))
|
|
used `cloned` where `copied` could be used instead:
ublox-short-range/src/command/edm/mod.rs#L112
warning: used `cloned` where `copied` could be used instead
--> ublox-short-range/src/command/edm/mod.rs:112:10
|
112 | .cloned()
| ^^^^^^ help: try: `copied`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cloned_instead_of_copied
|
casting `usize` to `u16` may truncate the value:
ublox-short-range/src/command/edm/mod.rs#L103
warning: casting `usize` to `u16` may truncate the value
--> ublox-short-range/src/command/edm/mod.rs:103:27
|
103 | let payload_len = (at_vec.len() + 2) as u16;
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
help: ... or use `try_from` and handle the error accordingly
|
103 | let payload_len = u16::try_from(at_vec.len() + 2);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
use Option::map_or_else instead of an if let/else:
ublox-short-range/src/command/edm/mod.rs#L73
warning: use Option::map_or_else instead of an if let/else
--> ublox-short-range/src/command/edm/mod.rs:73:13
|
73 | / match resp
74 | | .windows(b"\r\nOK".len())
75 | | .position(|window| window == b"\r\nOK")
76 | | {
... |
81 | | None => Ok(&resp[AT_COMMAND_POSITION..PAYLOAD_POSITION + payload_len]),
82 | | }
| |_____________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
help: try
|
73 ~ resp
74 + .windows(b"\r\nOK".len())
75 + .position(|window| window == b"\r\nOK").map_or_else(|| Ok(&resp[AT_COMMAND_POSITION..PAYLOAD_POSITION + payload_len]), |pos| Ok(&resp[AT_COMMAND_POSITION..pos]))
|
|
used `cloned` where `copied` could be used instead:
ublox-short-range/src/command/edm/mod.rs#L46
warning: used `cloned` where `copied` could be used instead
--> ublox-short-range/src/command/edm/mod.rs:46:10
|
46 | .cloned()
| ^^^^^^ help: try: `copied`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cloned_instead_of_copied
= note: `-W clippy::cloned-instead-of-copied` implied by `-W clippy::pedantic`
|
casting `usize` to `u16` may truncate the value:
ublox-short-range/src/command/edm/mod.rs#L37
warning: casting `usize` to `u16` may truncate the value
--> ublox-short-range/src/command/edm/mod.rs:37:27
|
37 | let payload_len = (at_vec.len() + 2) as u16;
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
= note: `-W clippy::cast-possible-truncation` implied by `-W clippy::pedantic`
help: ... or use `try_from` and handle the error accordingly
|
37 | let payload_len = u16::try_from(at_vec.len() + 2);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
usage of wildcard import:
ublox-short-range/src/command/edm/mod.rs#L13
warning: usage of wildcard import
--> ublox-short-range/src/command/edm/mod.rs:13:5
|
13 | use types::*;
| ^^^^^^^^ help: try: `types::{AT_COMMAND_POSITION, ChannelId, EDM_FULL_SIZE_FILTER, EDM_OVERHEAD, EDM_SIZE_FILTER, ENDBYTE, PAYLOAD_OVERHEAD, PAYLOAD_POSITION, PayloadType, STARTBYTE}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L156
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:156:40
|
156 | PayloadType::StartEvent => EdmEvent::StartUp.into(),
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L139
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:139:17
|
139 | EdmEvent::DisconnectEvent(ChannelId(resp[5])).into()
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L129
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:129:25
|
129 | EdmEvent::IPv6ConnectEvent(event).into()
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
casting `u8` to `u16` may become silently lossy if you later change the type:
ublox-short-range/src/command/edm/urc.rs#L123
warning: casting `u8` to `u16` may become silently lossy if you later change the type
--> ublox-short-range/src/command/edm/urc.rs:123:68
|
123 | ... local_port: ((resp[42] as u16) << 8) | resp[43] as u16,
| ^^^^^^^^^^^^^^^ help: try: `u16::from(resp[43])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless
|
casting `u8` to `u16` may become silently lossy if you later change the type:
ublox-short-range/src/command/edm/urc.rs#L123
warning: casting `u8` to `u16` may become silently lossy if you later change the type
--> ublox-short-range/src/command/edm/urc.rs:123:42
|
123 | ... local_port: ((resp[42] as u16) << 8) | resp[43] as u16,
| ^^^^^^^^^^^^^^^^^ help: try: `u16::from(resp[42])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless
|
casting `u8` to `u16` may become silently lossy if you later change the type:
ublox-short-range/src/command/edm/urc.rs#L117
warning: casting `u8` to `u16` may become silently lossy if you later change the type
--> ublox-short-range/src/command/edm/urc.rs:117:69
|
117 | ... remote_port: ((resp[24] as u16) << 8) | resp[25] as u16,
| ^^^^^^^^^^^^^^^ help: try: `u16::from(resp[25])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless
|
casting `u8` to `u16` may become silently lossy if you later change the type:
ublox-short-range/src/command/edm/urc.rs#L117
warning: casting `u8` to `u16` may become silently lossy if you later change the type
--> ublox-short-range/src/command/edm/urc.rs:117:43
|
117 | ... remote_port: ((resp[24] as u16) << 8) | resp[25] as u16,
| ^^^^^^^^^^^^^^^^^ help: try: `u16::from(resp[24])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L103
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:103:25
|
103 | EdmEvent::IPv4ConnectEvent(event).into()
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
casting `u8` to `u16` may become silently lossy if you later change the type:
ublox-short-range/src/command/edm/urc.rs#L97
warning: casting `u8` to `u16` may become silently lossy if you later change the type
--> ublox-short-range/src/command/edm/urc.rs:97:68
|
97 | ... local_port: ((resp[18] as u16) << 8) | resp[19] as u16,
| ^^^^^^^^^^^^^^^ help: try: `u16::from(resp[19])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless
|
casting `u8` to `u16` may become silently lossy if you later change the type:
ublox-short-range/src/command/edm/urc.rs#L97
warning: casting `u8` to `u16` may become silently lossy if you later change the type
--> ublox-short-range/src/command/edm/urc.rs:97:42
|
97 | ... local_port: ((resp[18] as u16) << 8) | resp[19] as u16,
| ^^^^^^^^^^^^^^^^^ help: try: `u16::from(resp[18])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless
|
casting `u8` to `u16` may become silently lossy if you later change the type:
ublox-short-range/src/command/edm/urc.rs#L95
warning: casting `u8` to `u16` may become silently lossy if you later change the type
--> ublox-short-range/src/command/edm/urc.rs:95:69
|
95 | ... remote_port: ((resp[12] as u16) << 8) | resp[13] as u16,
| ^^^^^^^^^^^^^^^ help: try: `u16::from(resp[13])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless
|
casting `u8` to `u16` may become silently lossy if you later change the type:
ublox-short-range/src/command/edm/urc.rs#L95
warning: casting `u8` to `u16` may become silently lossy if you later change the type
--> ublox-short-range/src/command/edm/urc.rs:95:43
|
95 | ... remote_port: ((resp[12] as u16) << 8) | resp[13] as u16,
| ^^^^^^^^^^^^^^^^^ help: try: `u16::from(resp[12])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless
= note: `-W clippy::cast-lossless` implied by `-W clippy::pedantic`
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L78
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:78:17
|
78 | EdmEvent::ATEvent(cmd).into()
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
this expression creates a reference which is immediately dereferenced by the compiler:
ublox-short-range/src/command/edm/urc.rs#L62
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> ublox-short-range/src/command/edm/urc.rs:62:77
|
62 | defmt::error!("[Parse URC Start/End byte Error] {:?}", LossyStr(&resp));
| ^^^^^ help: change this to: `resp`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L55
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:55:20
|
55 | return EdmEvent::StartUp.into();
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L47
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:47:24
|
47 | return EdmEvent::ATEvent(cmd).into();
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L37
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:37:24
|
37 | return EdmEvent::ATEvent(Urc::StartUp).into();
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
this function has too many lines (120/100):
ublox-short-range/src/command/edm/urc.rs#L28
warning: this function has too many lines (120/100)
--> ublox-short-range/src/command/edm/urc.rs:28:5
|
28 | / fn parse(resp: &[u8]) -> Option<Self::Response> {
29 | | defmt::trace!("[Parse URC] {:?}", LossyStr(resp));
30 | | // Startup message?
31 | | // TODO: simplify mayby no packet check.
... |
162 | | }
163 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/urc.rs#L25
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/urc.rs:25:21
|
25 | type Response = EdmEvent;
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
usage of wildcard import:
ublox-short-range/src/command/edm/urc.rs#L2
warning: usage of wildcard import
--> ublox-short-range/src/command/edm/urc.rs:2:5
|
2 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::{AT_COMMAND_POSITION, AUTOCONNECTMESSAGE, BluetoothConnectEvent, ChannelId, ConnectType, DataEvent, EDM_OVERHEAD, ENDBYTE, IPv4ConnectEvent, IPv6ConnectEvent, PAYLOAD_OVERHEAD, PAYLOAD_POSITION, PayloadType, Protocol, STARTBYTE, STARTUPMESSAGE}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L167
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:167:18
|
167 | _ => Protocol::Unknown,
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L166
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:166:18
|
166 | 1 => Protocol::UDP,
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L165
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:165:18
|
165 | 0 => Protocol::TCP,
| ^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/edm/types.rs#L154
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/edm/types.rs:154:24
|
154 | #[derive(Debug, Clone, PartialEq)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L149
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:149:18
|
149 | _ => ConnectType::Unknown,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L148
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:148:18
|
148 | 3 => ConnectType::IPv6,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L147
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:147:18
|
147 | 2 => ConnectType::IPv4,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L146
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:146:18
|
146 | 1 => ConnectType::Bluetooth,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/edm/types.rs#L134
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/edm/types.rs:134:30
|
134 | #[derive(Debug, Clone, Copy, PartialEq)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/edm/types.rs#L126
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/edm/types.rs:126:30
|
126 | #[derive(Debug, Clone, Copy, PartialEq)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/edm/types.rs#L120
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/edm/types.rs:120:24
|
120 | #[derive(Debug, Clone, PartialEq)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L88
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:88:18
|
88 | _ => PayloadType::Unknown,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L87
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:87:21
|
87 | 0x71 => PayloadType::StartEvent,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L86
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:86:21
|
86 | 0x61 => PayloadType::IPhoneEvent,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L85
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:85:21
|
85 | 0x56 => PayloadType::ResendConnectEventsCommand,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L84
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:84:21
|
84 | 0x41 => PayloadType::ATEvent,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L83
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:83:21
|
83 | 0x45 => PayloadType::ATConfirmation,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L82
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:82:21
|
82 | 0x44 => PayloadType::ATRequest,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L81
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:81:21
|
81 | 0x36 => PayloadType::DataCommand,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L80
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:80:21
|
80 | 0x31 => PayloadType::DataEvent,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L79
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:79:21
|
79 | 0x21 => PayloadType::DisconnectEvent,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
unnecessary structure name repetition:
ublox-short-range/src/command/edm/types.rs#L78
warning: unnecessary structure name repetition
--> ublox-short-range/src/command/edm/types.rs:78:21
|
78 | 0x11 => PayloadType::ConnectEvent,
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
|
usage of wildcard import:
ublox-short-range/src/command/data_mode/mod.rs#L9
warning: usage of wildcard import
--> ublox-short-range/src/command/data_mode/mod.rs:9:5
|
9 | use types::*;
| ^^^^^^^^ help: try: `types::{ConnectScheme, Mode, PeerConfigParameter, RemoteConfiguration, ServerType, WatchdogSetting}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
usage of wildcard import:
ublox-short-range/src/command/data_mode/mod.rs#L8
warning: usage of wildcard import
--> ublox-short-range/src/command/data_mode/mod.rs:8:5
|
8 | use responses::*;
| ^^^^^^^^^^^^ help: try: `responses::{BindResponse, ConnectPeerResponse, PeerListResponse}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/urc.rs#L32
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/urc.rs:32:17
|
32 | #[derive(Debug, PartialEq, Clone, AtatResp)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
usage of wildcard import:
ublox-short-range/src/command/data_mode/urc.rs#L4
warning: usage of wildcard import
--> ublox-short-range/src/command/data_mode/urc.rs:4:5
|
4 | use super::types::*;
| ^^^^^^^^^^^^^^^ help: try: `super::types::{ConnectionType, IPProtocol}`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wildcard_imports
= note: `-W clippy::wildcard-imports` implied by `-W clippy::pedantic`
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L238
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:238:24
|
238 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L220
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:220:24
|
220 | #[derive(Debug, Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L107
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:107:17
|
107 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L99
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:99:17
|
99 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L92
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:92:17
|
92 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L77
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:77:17
|
77 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L65
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:65:17
|
65 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L21
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:21:17
|
21 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/command/data_mode/types.rs#L7
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/command/data_mode/types.rs:7:17
|
7 | #[derive(Clone, PartialEq, AtatEnum)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
|
this expression creates a reference which is immediately dereferenced by the compiler:
ublox-short-range/src/command/custom_digest.rs#L70
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> ublox-short-range/src/command/custom_digest.rs:70:51
|
70 | defmt::trace!("Digest {:?}", LossyStr(&buf));
| ^^^^ help: change this to: `buf`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
|
this could be rewritten as `let...else`:
ublox-short-range/src/command/custom_digest.rs#L47
warning: this could be rewritten as `let...else`
--> ublox-short-range/src/command/custom_digest.rs:47:9
|
47 | / let start_pos = match buf.windows(1).position(|byte| byte[0] == STARTBYTE) {
48 | | Some(pos) => pos,
49 | | None => return (DigestResult::None, 0), // handle leading error data. // TODO: handle error input without message start.
50 | | };
| |__________^ help: consider writing: `let Some(start_pos) = buf.windows(1).position(|byte| byte[0] == STARTBYTE) else { return (DigestResult::None, 0) };`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
= note: `-W clippy::manual-let-else` implied by `-W clippy::pedantic`
|
this expression creates a reference which is immediately dereferenced by the compiler:
ublox-short-range/src/command/custom_digest.rs#L21
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> ublox-short-range/src/command/custom_digest.rs:21:47
|
21 | defmt::trace!("Digest {:?}", LossyStr(&buf));
| ^^^^ help: change this to: `buf`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
= note: `-W clippy::needless-borrow` implied by `-W clippy::all`
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/hex.rs#L28
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/hex.rs:28:9
|
28 | hex[i] = val(hex[i * 2])? << 4 | val(hex[i * 2 + 1])?
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add a `;` here: `hex[i] = val(hex[i * 2])? << 4 | val(hex[i * 2 + 1])?;`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
|
item name ends with its containing module's name:
ublox-short-range/src/hex.rs#L21
warning: item name ends with its containing module's name
--> ublox-short-range/src/hex.rs:21:8
|
21 | pub fn from_hex(hex: &mut [u8]) -> Result<&[u8], FromHexError> {
| ^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
|
this could be a `const fn`:
ublox-short-range/src/hex.rs#L12
warning: this could be a `const fn`
--> ublox-short-range/src/hex.rs:12:1
|
12 | / fn val(c: u8) -> Result<u8, FromHexError> {
13 | | match c {
14 | | b'A'..=b'F' => Ok(c - b'A' + 10),
15 | | b'a'..=b'f' => Ok(c - b'a' + 10),
... |
18 | | }
19 | | }
| |_^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
|
you are deriving `PartialEq` and can implement `Eq`:
ublox-short-range/src/hex.rs#L1
warning: you are deriving `PartialEq` and can implement `Eq`
--> ublox-short-range/src/hex.rs:1:30
|
1 | #[derive(Debug, Clone, Copy, PartialEq)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
= note: `-W clippy::derive-partial-eq-without-eq` implied by `-W clippy::nursery`
|
use Option::map_or instead of an if let/else:
ublox-short-range/src/client.rs#L939
warning: use Option::map_or instead of an if let/else
--> ublox-short-range/src/client.rs:939:9
|
939 | / if let Some(ref con) = self.wifi_connection {
940 | | if !self.initialized {
941 | | Err(Error::Uninitialized)
942 | | // } else if !(con.network_state == NetworkState::Attached) {
... |
953 | | Err(Error::NoWifiSetup)
954 | | }
| |_________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
help: try
|
939 ~ self.wifi_connection.as_ref().map_or(Err(Error::NoWifiSetup), |con| if !self.initialized {
940 + Err(Error::Uninitialized)
941 + // } else if !(con.network_state == NetworkState::Attached) {
942 + } else if !con.is_connected() {
943 + if con.wifi_state == WiFiState::Connected {
944 + Err(Error::NetworkState(con.network_state))
945 + } else {
946 + Err(Error::WifiState(con.wifi_state))
947 + }
948 + } else {
949 + Ok(())
950 + })
|
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L938
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:938:5
|
938 | pub fn attached_to_wifi(&self) -> Result<(), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
item in documentation is missing backticks:
ublox-short-range/src/client.rs#L933
warning: item in documentation is missing backticks
--> ublox-short-range/src/client.rs:933:37
|
933 | /// Is the module attached to a WiFi
| ^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
help: try
|
933 | /// Is the module attached to a `WiFi`
| ~~~~~~
|
use Option::map_or instead of an if let/else:
ublox-short-range/src/client.rs#L918
warning: use Option::map_or instead of an if let/else
--> ublox-short-range/src/client.rs:918:9
|
918 | / if let Some(ref con) = self.wifi_connection {
919 | | if !self.initialized {
920 | | Err(Error::Uninitialized)
921 | | } else if !con.is_connected() {
... |
929 | | Err(Error::NoWifiSetup)
930 | | }
| |_________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
help: try
|
918 ~ self.wifi_connection.as_ref().map_or(Err(Error::NoWifiSetup), |con| if !self.initialized {
919 + Err(Error::Uninitialized)
920 + } else if !con.is_connected() {
921 + Err(Error::WifiState(con.wifi_state))
922 + } else if self.sockets.is_none() {
923 + Err(Error::MissingSocketSet)
924 + } else {
925 + Ok(())
926 + })
|
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L917
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:917:5
|
917 | pub fn connected_to_network(&self) -> Result<(), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
item in documentation is missing backticks:
ublox-short-range/src/client.rs#L916
warning: item in documentation is missing backticks
--> ublox-short-range/src/client.rs:916:37
|
916 | /// Is the module attached to a WiFi and ready to open sockets
| ^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
= note: `-W clippy::doc-markdown` implied by `-W clippy::pedantic`
help: try
|
916 | /// Is the module attached to a `WiFi` and ready to open sockets
| ~~~~~~
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L904
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:904:5
|
904 | pub fn supplicant<const M: usize>(&mut self) -> Result<Supplicant<C, M>, Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L891
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:891:5
|
891 | / pub fn send_at<A, const LEN: usize>(&mut self, cmd: A) -> Result<A::Response, Error>
892 | | where
893 | | A: atat::AtatCmd<LEN>,
| |______________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
unnecessary boolean `not` operation:
ublox-short-range/src/client.rs#L828
warning: unnecessary boolean `not` operation
--> ublox-short-range/src/client.rs:828:25
|
828 | / if !event.data.is_empty() {
829 | | if let Some(socket_handle) =
830 | | socket_map.channel_to_socket(&event.channel_id)
831 | | {
... |
867 | | false
868 | | }
| |_________________________^
|
= help: remove the `!` and swap the blocks of the `if`/`else`
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#if_not_else
= note: `-W clippy::if-not-else` implied by `-W clippy::pedantic`
|
wildcard matches only a single variant and will also match any future added variants:
ublox-short-range/src/client.rs#L806
warning: wildcard matches only a single variant and will also match any future added variants
--> ublox-short-range/src/client.rs:806:41
|
806 | ... _ => {}
| ^ help: try this: `Protocol::Unknown`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_wildcard_for_single_variants
|
wildcard matches only a single variant and will also match any future added variants:
ublox-short-range/src/client.rs#L759
warning: wildcard matches only a single variant and will also match any future added variants
--> ublox-short-range/src/client.rs:759:41
|
759 | ... _ => {}
| ^ help: try this: `Protocol::Unknown`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_wildcard_for_single_variants
= note: `-W clippy::match-wildcard-for-single-variants` implied by `-W clippy::pedantic`
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/client.rs#L685
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/client.rs:685:45
|
685 | ... con.network_state = NetworkState::AlmostAttached
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add a `;` here: `con.network_state = NetworkState::AlmostAttached;`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/client.rs#L682
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/client.rs:682:45
|
682 | ... con.network_state = NetworkState::Attached
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add a `;` here: `con.network_state = NetworkState::Attached;`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L555
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:555:41
|
555 | ... IPProtocol::UDP => {
| ^--------------
| |
| _______________________help: try merging the arm patterns: `IPProtocol::UDP | IPProtocol::TCP`
| |
556 | | ... // if let Ok(mut udp) =
557 | | ... // sockets.get::<UdpSocket<TIMER_HZ, L>>(event.handle)
558 | | ... // {
... |
567 | | ... // }
568 | | ... }
| |_______________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:542:41
|
542 | / ... IPProtocol::TCP => {
543 | | ... // if let Ok(mut tcp) =
544 | | ... // sockets.get::<TcpSocket<CLK, L>>(event.handle)
545 | | ... // {
... |
553 | | ... // }
554 | | ... }
| |_______________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/client.rs#L537
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/client.rs:537:41
|
537 | ... handled = false
| ^^^^^^^^^^^^^^^ help: add a `;` here: `handled = false;`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
|
consider adding a `;` to the last statement for consistent formatting:
ublox-short-range/src/client.rs#L520
warning: consider adding a `;` to the last statement for consistent formatting
--> ublox-short-range/src/client.rs:520:41
|
520 | ... handled = false
| ^^^^^^^^^^^^^^^ help: add a `;` here: `handled = false;`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#semicolon_if_nothing_returned
= note: `-W clippy::semicolon-if-nothing-returned` implied by `-W clippy::pedantic`
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L671
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:671:25
|
671 | Urc::EthernetLinkDown(_) => {
| ^-----------------------
| |
| _________________________help: try merging the arm patterns: `Urc::EthernetLinkDown(_) | Urc::NetworkError(_)`
| |
672 | | debug!("[URC] EthernetLinkDown");
673 | | true
674 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:701:25
|
701 | / Urc::NetworkError(_) => {
702 | | debug!("[URC] NetworkError");
703 | | true
704 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L667
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:667:25
|
667 | Urc::EthernetLinkUp(_) => {
| ^---------------------
| |
| _________________________help: try merging the arm patterns: `Urc::EthernetLinkUp(_) | Urc::NetworkError(_)`
| |
668 | | debug!("[URC] EthernetLinkUp");
669 | | true
670 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:701:25
|
701 | / Urc::NetworkError(_) => {
702 | | debug!("[URC] NetworkError");
703 | | true
704 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L663
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:663:25
|
663 | Urc::WifiAPStationDisconnected(_) => {
| ^--------------------------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPStationDisconnected(_) | Urc::NetworkError(_)`
| |
664 | | debug!("[URC] WifiAPStationDisconnected");
665 | | true
666 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:701:25
|
701 | / Urc::NetworkError(_) => {
702 | | debug!("[URC] NetworkError");
703 | | true
704 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L652
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:652:25
|
652 | Urc::WifiAPDown(_) => {
| ^-----------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPDown(_) | Urc::NetworkError(_)`
| |
653 | | debug!("[URC] WifiAPDown");
654 | | true
655 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:701:25
|
701 | / Urc::NetworkError(_) => {
702 | | debug!("[URC] NetworkError");
703 | | true
704 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L648
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:648:25
|
648 | Urc::WifiAPUp(_) => {
| ^---------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPUp(_) | Urc::NetworkError(_)`
| |
649 | | debug!("[URC] WifiAPUp");
650 | | true
651 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:701:25
|
701 | / Urc::NetworkError(_) => {
702 | | debug!("[URC] NetworkError");
703 | | true
704 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L667
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:667:25
|
667 | Urc::EthernetLinkUp(_) => {
| ^---------------------
| |
| _________________________help: try merging the arm patterns: `Urc::EthernetLinkUp(_) | Urc::EthernetLinkDown(_)`
| |
668 | | debug!("[URC] EthernetLinkUp");
669 | | true
670 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:671:25
|
671 | / Urc::EthernetLinkDown(_) => {
672 | | debug!("[URC] EthernetLinkDown");
673 | | true
674 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L663
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:663:25
|
663 | Urc::WifiAPStationDisconnected(_) => {
| ^--------------------------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPStationDisconnected(_) | Urc::EthernetLinkDown(_)`
| |
664 | | debug!("[URC] WifiAPStationDisconnected");
665 | | true
666 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:671:25
|
671 | / Urc::EthernetLinkDown(_) => {
672 | | debug!("[URC] EthernetLinkDown");
673 | | true
674 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L652
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:652:25
|
652 | Urc::WifiAPDown(_) => {
| ^-----------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPDown(_) | Urc::EthernetLinkDown(_)`
| |
653 | | debug!("[URC] WifiAPDown");
654 | | true
655 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:671:25
|
671 | / Urc::EthernetLinkDown(_) => {
672 | | debug!("[URC] EthernetLinkDown");
673 | | true
674 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L648
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:648:25
|
648 | Urc::WifiAPUp(_) => {
| ^---------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPUp(_) | Urc::EthernetLinkDown(_)`
| |
649 | | debug!("[URC] WifiAPUp");
650 | | true
651 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:671:25
|
671 | / Urc::EthernetLinkDown(_) => {
672 | | debug!("[URC] EthernetLinkDown");
673 | | true
674 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L663
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:663:25
|
663 | Urc::WifiAPStationDisconnected(_) => {
| ^--------------------------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPStationDisconnected(_) | Urc::EthernetLinkUp(_)`
| |
664 | | debug!("[URC] WifiAPStationDisconnected");
665 | | true
666 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:667:25
|
667 | / Urc::EthernetLinkUp(_) => {
668 | | debug!("[URC] EthernetLinkUp");
669 | | true
670 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L652
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:652:25
|
652 | Urc::WifiAPDown(_) => {
| ^-----------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPDown(_) | Urc::EthernetLinkUp(_)`
| |
653 | | debug!("[URC] WifiAPDown");
654 | | true
655 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:667:25
|
667 | / Urc::EthernetLinkUp(_) => {
668 | | debug!("[URC] EthernetLinkUp");
669 | | true
670 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L648
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:648:25
|
648 | Urc::WifiAPUp(_) => {
| ^---------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPUp(_) | Urc::EthernetLinkUp(_)`
| |
649 | | debug!("[URC] WifiAPUp");
650 | | true
651 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:667:25
|
667 | / Urc::EthernetLinkUp(_) => {
668 | | debug!("[URC] EthernetLinkUp");
669 | | true
670 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L652
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:652:25
|
652 | Urc::WifiAPDown(_) => {
| ^-----------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPDown(_) | Urc::WifiAPStationDisconnected(_)`
| |
653 | | debug!("[URC] WifiAPDown");
654 | | true
655 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:663:25
|
663 | / Urc::WifiAPStationDisconnected(_) => {
664 | | debug!("[URC] WifiAPStationDisconnected");
665 | | true
666 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L648
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:648:25
|
648 | Urc::WifiAPUp(_) => {
| ^---------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPUp(_) | Urc::WifiAPStationDisconnected(_)`
| |
649 | | debug!("[URC] WifiAPUp");
650 | | true
651 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:663:25
|
663 | / Urc::WifiAPStationDisconnected(_) => {
664 | | debug!("[URC] WifiAPStationDisconnected");
665 | | true
666 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
|
this match arm has an identical body to another arm:
ublox-short-range/src/client.rs#L648
warning: this match arm has an identical body to another arm
--> ublox-short-range/src/client.rs:648:25
|
648 | Urc::WifiAPUp(_) => {
| ^---------------
| |
| _________________________help: try merging the arm patterns: `Urc::WifiAPUp(_) | Urc::WifiAPDown(_)`
| |
649 | | debug!("[URC] WifiAPUp");
650 | | true
651 | | }
| |_________________________^
|
= help: or try changing either arm body
note: other arm here
--> ublox-short-range/src/client.rs:652:25
|
652 | / Urc::WifiAPDown(_) => {
653 | | debug!("[URC] WifiAPDown");
654 | | true
655 | | }
| |_________________________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_same_arms
= note: `-W clippy::match-same-arms` implied by `-W clippy::pedantic`
|
the function has a cognitive complexity of (45/25):
ublox-short-range/src/client.rs#L470
warning: the function has a cognitive complexity of (45/25)
--> ublox-short-range/src/client.rs:470:54
|
470 | self.client.try_read_urc_with::<EdmEvent, _>(|edm_urc, _| {
| ^^^^^^^^^^^^
|
= help: you could split it up into multiple smaller functions
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cognitive_complexity
= note: `-W clippy::cognitive-complexity` implied by `-W clippy::nursery`
|
this function has too many lines (377/100):
ublox-short-range/src/client.rs#L459
warning: this function has too many lines (377/100)
--> ublox-short-range/src/client.rs:459:5
|
459 | / fn handle_urc(&mut self) -> Result<bool, Error> {
460 | | let mut ran = false;
461 | | let socket_set = self.sockets.as_deref_mut();
462 | | let socket_map = &mut self.socket_map;
... |
886 | | Ok(ran)
887 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
= note: `-W clippy::too-many-lines` implied by `-W clippy::pedantic`
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L422
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:422:5
|
422 | pub fn spin(&mut self) -> Result<(), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L376
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:376:5
|
376 | pub fn software_reset(&mut self) -> Result<(), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L338
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:338:5
|
338 | pub fn reset(&mut self) -> Result<(), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L319
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:319:5
|
319 | / pub fn retry_send<A, const LEN: usize>(
320 | | &mut self,
321 | | cmd: &A,
322 | | attempts: usize,
323 | | ) -> Result<A::Response, Error>
324 | | where
325 | | A: atat::AtatCmd<LEN>,
| |______________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L304
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:304:5
|
304 | pub fn signal_strength(&mut self) -> Result<i16, Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L299
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:299:5
|
299 | pub fn firmware_version(&mut self) -> Result<FirmwareVersion, Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
|
docs for function returning `Result` missing `# Errors` section:
ublox-short-range/src/client.rs#L211
warning: docs for function returning `Result` missing `# Errors` section
--> ublox-short-range/src/client.rs:211:5
|
211 | pub fn init(&mut self) -> Result<(), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc
= note: `-W clippy::missing-errors-doc` implied by `-W clippy::pedantic`
|
unnecessary structure name repetition:
ublox-short-range/src/client.rs#L180
warning: unnecessary structure name repetition
--> ublox-short-range/src/client.rs:180:9
|
180 | UbloxClient {
| ^^^^^^^^^^^ help: use the applicable keyword: `Self`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#use_self
= note: `-W clippy::use-self` implied by `-W clippy::nursery`
|
item name ends with its containing module's name:
ublox-short-range/src/client.rs#L150
warning: item name ends with its containing module's name
--> ublox-short-range/src/client.rs:150:12
|
150 | pub struct UbloxClient<C, CLK, RST, const TIMER_HZ: u32, const N: usize, const L: usize>
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
= note: `-W clippy::module-name-repetitions` implied by `-W clippy::pedantic`
|
use Option::map_or instead of an if let/else:
ublox-short-range/src/client.rs#L117
warning: use Option::map_or instead of an if let/else
--> ublox-short-range/src/client.rs:117:9
|
117 | / match self
118 | | .table
119 | | .iter()
120 | | .find(|e| e.state == DNSState::Resolved(ip))
... |
123 | | None => None,
124 | | }
| |_________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
= note: `-W clippy::option-if-let-else` implied by `-W clippy::nursery`
help: try
|
117 ~ self
118 + .table
119 + .iter()
120 + .find(|e| e.state == DNSState::Resolved(ip)).map_or(None, |entry| Some(&entry.domain_name))
|
|
this argument is passed by value, but not consumed in the function body:
ublox-short-range/src/client.rs#L109
warning: this argument is passed by value, but not consumed in the function body
--> ublox-short-range/src/client.rs:109:22
|
109 | domain_name: heapless::String<MAX_DOMAIN_NAME_LENGTH>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider taking a reference instead: `&heapless::String<MAX_DOMAIN_NAME_LENGTH>`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
= note: `-W clippy::needless-pass-by-value` implied by `-W clippy::pedantic`
|
this could be a `const fn`:
ublox-short-range/src/client.rs#L74
warning: this could be a `const fn`
--> ublox-short-range/src/client.rs:74:5
|
74 | / pub fn new(state: DNSState, domain_name: heapless::String<MAX_DOMAIN_NAME_LENGTH>) -> Self {
75 | | Self { domain_name, state }
76 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
= note: `-W clippy::missing-const-for-fn` implied by `-W clippy::nursery`
|
unneeded unit expression:
ublox-short-range/src/wifi/tcp_stack.rs#L221
warning: unneeded unit expression
--> ublox-short-range/src/wifi/tcp_stack.rs:221:33
|
221 | ... ()
| ^^ help: remove the final `()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit
= note: `-W clippy::unused-unit` implied by `-W clippy::all`
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L121
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:121:16
|
121 | B5250000 = 5250000,
| ^^^^^^^ help: consider: `5_250_000`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L120
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:120:16
|
120 | B3000000 = 3000000,
| ^^^^^^^ help: consider: `3_000_000`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L119
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:119:15
|
119 | B921600 = 921600,
| ^^^^^^ help: consider: `921_600`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L118
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:118:15
|
118 | B460800 = 460800,
| ^^^^^^ help: consider: `460_800`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L117
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:117:15
|
117 | B250000 = 250000,
| ^^^^^^ help: consider: `250_000`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L116
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:116:15
|
116 | B230400 = 230400,
| ^^^^^^ help: consider: `230_400`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L115
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:115:15
|
115 | B115200 = 115200,
| ^^^^^^ help: consider: `115_200`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L69
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:69:15
|
69 | B460800 = 460800,
| ^^^^^^ help: consider: `460_800`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L68
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:68:15
|
68 | B230400 = 230400,
| ^^^^^^ help: consider: `230_400`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
|
long literal lacking separators:
ublox-short-range/src/command/system/types.rs#L67
warning: long literal lacking separators
--> ublox-short-range/src/command/system/types.rs:67:15
|
67 | B115200 = 115200,
| ^^^^^^ help: consider: `115_200`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unreadable_literal
= note: `-W clippy::unreadable-literal` implied by `-W clippy::pedantic`
|
redundant else block:
ublox-short-range/src/command/custom_digest.rs#L34
warning: redundant else block
--> ublox-short-range/src/command/custom_digest.rs:34:24
|
34 | } else {
| ________________________^
35 | | return (DigestResult::None, len);
36 | | }
| |_________________^
|
= help: remove the `else` block and move the contents out
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_else
= note: `-W clippy::redundant-else` implied by `-W clippy::pedantic`
|
found an empty line after a doc comment. Perhaps you need to use `//!` to make a comment on a module, remove the empty line, or make a regular comment with `//`?:
ublox-short-range/src/wifi/mod.rs#L26
warning: found an empty line after a doc comment. Perhaps you need to use `//!` to make a comment on a module, remove the empty line, or make a regular comment with `//`?
--> ublox-short-range/src/wifi/mod.rs:26:1
|
26 | / /// data over the connection in EDM mode.
27 | |
28 | | pub enum SocketMapError {
| |_
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments
|
found an empty line after a doc comment. Perhaps you need to use `//!` to make a comment on a module, remove the empty line, or make a regular comment with `//`?:
ublox-short-range/src/command/ping/types.rs#L25
warning: found an empty line after a doc comment. Perhaps you need to use `//!` to make a comment on a module, remove the empty line, or make a regular comment with `//`?
--> ublox-short-range/src/command/ping/types.rs:25:1
|
25 | / /// - Default value: 1000
26 | | // pub type Inteval = u16;
27 | |
28 | | #[derive(Debug, PartialEq, Clone, Copy, AtatEnum, defmt::Format)]
29 | | #[repr(u8)]
30 | | pub enum PingError {
| |_
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments
|
found an empty line after a doc comment. Perhaps you need to use `//!` to make a comment on a module, remove the empty line, or make a regular comment with `//`?:
ublox-short-range/src/command/edm/types.rs#L6
warning: found an empty line after a doc comment. Perhaps you need to use `//!` to make a comment on a module, remove the empty line, or make a regular comment with `//`?
--> ublox-short-range/src/command/edm/types.rs:6:1
|
6 | / /// Start byte, Length: u16, Id+Type: u16, Endbyte
7 | | // type EdmAtCmdOverhead = (u8, u16, u16, u8);
8 | |
9 | | #[derive(
... |
23 | | )]
24 | | pub struct ChannelId(pub u8);
| |_
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments
|
found an empty line after a doc comment. Perhaps you need to use `//!` to make a comment on a module, remove the empty line, or make a regular comment with `//`?:
ublox-short-range/src/client.rs#L60
warning: found an empty line after a doc comment. Perhaps you need to use `//!` to make a comment on a module, remove the empty line, or make a regular comment with `//`?
--> ublox-short-range/src/client.rs:60:1
|
60 | / /// .0 or later.
61 | |
62 | | #[cfg(not(feature = "nina_w1xx"))]
63 | | pub const MAX_DOMAIN_NAME_LENGTH: usize = 64;
| |_
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments
= note: `-W clippy::empty-line-after-doc-comments` implied by `-W clippy::nursery`
|