Skip to content

Commit

Permalink
#21 remove underscore prefix
Browse files Browse the repository at this point in the history
  • Loading branch information
HusseinAbdelhamid committed Sep 11, 2024
1 parent 69e0188 commit 75615e2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/message.rs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ pub struct TxHeader {

pub trait MessageType<const L: usize> {
/// Setup CAN message header depending on message type
fn setup_header(&self, _header: &mut TxHeader, payload_length: usize) -> Result<(), MessageError>;
fn setup_header(&self, header: &mut TxHeader, payload_length: usize) -> Result<(), MessageError>;
}

/// CAN 2.0 message type where `L` is the max number of payload bytes.
Expand All @@ -110,7 +110,7 @@ pub trait MessageType<const L: usize> {
pub struct Can20<const L: usize> {}

impl<const L: usize> MessageType<L> for Can20<L> {
fn setup_header(&self, _header: &mut TxHeader, payload_length: usize) -> Result<(), MessageError> {
fn setup_header(&self, header: &mut TxHeader, payload_length: usize) -> Result<(), MessageError> {
if L > 8 || payload_length > 8 {
let max = payload_length.max(L);
debug!("Maximum of 64 bytes allowed. Current size: {max} bytes");
Expand Down

0 comments on commit 75615e2

Please sign in to comment.