Skip to content

Commit

Permalink
1.47 minor updates (#114)
Browse files Browse the repository at this point in the history
  • Loading branch information
zeeshanlakhani authored Nov 16, 2020
1 parent 8dfb2a1 commit d4edbb2
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 22 deletions.
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
- uses: actions-rs/audit-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
continue-on-error: true

- name: slack-it
uses: homoluctus/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion bench/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Benchmarks for Capsule.
capsule = { version = "0.1", path = "../core", features = ["testils"] }
criterion = "0.3"
failure = "0.1"
proptest = "0.9"
proptest = "0.10"

[[bench]]
name = "packets"
Expand Down
4 changes: 2 additions & 2 deletions core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ libc = "0.2"
metrics-core = { version = "0.5", optional = true }
metrics-runtime = { version = "0.12", optional = true, default-features = false }
once_cell = "1.2"
proptest = { version = "0.9", optional = true }
proptest = { version = "0.10", optional = true }
regex = "1"
serde = { version = "1.0", features = ["derive"] }
tokio = "=0.2.0-alpha.6"
Expand All @@ -42,7 +42,7 @@ tracing = "0.1"

[dev-dependencies]
criterion = "0.3"
proptest = { version = "0.9", default-features = false, features = ["default-code-coverage"] }
proptest = { version = "0.10", default-features = false, features = ["default-code-coverage"] }

[features]
default = ["metrics"]
Expand Down
20 changes: 4 additions & 16 deletions core/src/batch/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -87,34 +87,22 @@ impl<T: Packet> Disposition<T> {

/// Returns whether the disposition is `Act`.
pub fn is_act(&self) -> bool {
match self {
Disposition::Act(_) => true,
_ => false,
}
matches!(self, Disposition::Act(_))
}

/// Returns whether the disposition is `Emit`.
pub fn is_emit(&self) -> bool {
match self {
Disposition::Emit => true,
_ => false,
}
matches!(self, Disposition::Emit)
}

/// Returns whether the disposition is `Drop`.
pub fn is_drop(&self) -> bool {
match self {
Disposition::Drop(_) => true,
_ => false,
}
matches!(self, Disposition::Drop(_))
}

/// Returns whether the disposition is `Abort`.
pub fn is_abort(&self) -> bool {
match self {
Disposition::Abort(_) => true,
_ => false,
}
matches!(self, Disposition::Abort(_))
}
}

Expand Down
2 changes: 1 addition & 1 deletion core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
rust_2018_idioms,
unreachable_pub
)]
#![deny(intra_doc_link_resolution_failure)]
#![deny(broken_intra_doc_links)]
#![cfg_attr(docsrs, feature(doc_cfg))]
#![doc(html_root_url = "https://docs.rs/capsule/0.1.4")]

Expand Down
2 changes: 1 addition & 1 deletion ffi/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ name = "capsule_ffi"
doctest = false

[build-dependencies]
bindgen = "0.53"
bindgen = "0.55"
cc = "1.0"
libc = "0.2"

Expand Down
3 changes: 2 additions & 1 deletion macros/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
//! [`Capsule`]: https://crates.io/crates/capsule

#![recursion_limit = "128"]
#![allow(intra_doc_link_resolution_failure)]
#![allow(broken_intra_doc_links)]

mod derive_packet;

Expand Down Expand Up @@ -109,6 +109,7 @@ impl Default for AttrArgs {
/// ...
/// assert!(drop);
/// }
/// }
/// ```
#[proc_macro_attribute]
pub fn test(args: TokenStream, input: TokenStream) -> TokenStream {
Expand Down

0 comments on commit d4edbb2

Please sign in to comment.