Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade toolchain's version #95

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- name: Install Rust stable
uses: actions-rs/toolchain@v1
with:
toolchain: 1.81.0
toolchain: 1.84.0
override: true
components: rustfmt, clippy
- name: Set up Python ${{ matrix.python-version }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/rustdoc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Install Rust stable
uses: actions-rs/toolchain@v1
with:
toolchain: 1.81.0
toolchain: 1.84.0
override: true
components: rustfmt, clippy
- name: Set up Python ${{ matrix.python-version }}
Expand Down
2 changes: 1 addition & 1 deletion core/src/filter/hardware/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ impl<'a> HardwareFilter<'a> {
}
}

impl<'a> fmt::Display for HardwareFilter<'a> {
impl fmt::Display for HardwareFilter<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> Result<(), fmt::Error> {
writeln!(f, "[HardwareFilter]: ")?;
for pattern in self.patterns.iter() {
Expand Down
2 changes: 1 addition & 1 deletion core/src/memory/mempool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ impl fmt::Debug for Mempool {

/// Rounds `n` up to the nearest multiple of `s`
fn round_up(n: u32, s: u32) -> u32 {
((n + s - 1) / s) * s
n.div_ceil(s) * s
}

#[derive(Error, Debug)]
Expand Down
2 changes: 1 addition & 1 deletion core/src/protocols/packet/ethernet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ pub struct Ethernet<'a> {
mbuf: &'a Mbuf,
}

impl<'a> Ethernet<'a> {
impl Ethernet<'_> {
/// Returns the destination MAC address.
#[inline]
pub fn dst(&self) -> MacAddr {
Expand Down
2 changes: 1 addition & 1 deletion core/src/protocols/packet/ipv4.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ pub struct Ipv4<'a> {
mbuf: &'a Mbuf,
}

impl<'a> Ipv4<'a> {
impl Ipv4<'_> {
/// Returns the IP protocol version.
#[inline]
pub fn version(&self) -> u8 {
Expand Down
2 changes: 1 addition & 1 deletion core/src/protocols/packet/ipv6.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ pub struct Ipv6<'a> {
mbuf: &'a Mbuf,
}

impl<'a> Ipv6<'a> {
impl Ipv6<'_> {
/// Returns the IP protocol version.
#[inline]
pub fn version(&self) -> u8 {
Expand Down
2 changes: 1 addition & 1 deletion core/src/protocols/packet/tcp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ pub struct Tcp<'a> {
mbuf: &'a Mbuf,
}

impl<'a> Tcp<'a> {
impl Tcp<'_> {
/// Returns the sending port.
#[inline]
pub fn src_port(&self) -> u16 {
Expand Down
2 changes: 1 addition & 1 deletion core/src/protocols/packet/udp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ pub struct Udp<'a> {
mbuf: &'a Mbuf,
}

impl<'a> Udp<'a> {
impl Udp<'_> {
/// Returns the sending port.
#[inline]
pub fn src_port(&self) -> u16 {
Expand Down
1 change: 0 additions & 1 deletion core/src/subscription/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,6 @@ where
}

/// Delivery functions, including delivery to the correct callback

pub fn deliver_packet(&self, mbuf: &Mbuf, conn_data: &ConnData, tracked: &S::Tracked) {
(self.packet_deliver)(mbuf, conn_data, tracked)
}
Expand Down
2 changes: 1 addition & 1 deletion datatypes/src/conn_fts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ impl Tracked for InterArrivals {
}

struct DurationVec<'a>(&'a Vec<Duration>);
impl<'a> Serialize for DurationVec<'a> {
impl Serialize for DurationVec<'_> {
fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where
S: Serializer,
Expand Down
2 changes: 1 addition & 1 deletion datatypes/src/typedefs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ pub type SessionList = Vec<Session>;
/// The string literal representing a matched filter.
pub type FilterStr<'a> = &'a str;

impl<'a> FromSubscription for FilterStr<'a> {
impl FromSubscription for FilterStr<'_> {
fn from_subscription(spec: &SubscriptionSpec) -> proc_macro2::TokenStream {
let str = syn::LitStr::new(&spec.filter, Span::call_site());
quote! { &#str }
Expand Down
Loading