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

Update hashbrown dependency #444

Merged
merged 1 commit into from
Jun 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
33 changes: 23 additions & 10 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
matrix:
os: ["ubuntu-latest"]
rust_channel: ["stable", "beta", "nightly", "1.42.0"]
rust_channel: ["stable", "beta", "nightly"]
include:
- rust_channel: "stable"
os: "macOS-latest"
Expand All @@ -20,15 +20,10 @@ jobs:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install rustup
run: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile=minimal
- name: Install rust channel
run: |
rustup install ${{matrix.rust_channel}}
rustup default ${{matrix.rust_channel}}
- name: MSRV dependencies
if: matrix.rust_channel == '1.42.0'
run: cargo update -p indexmap --precise 1.6.2
- name: Test debug
run: cargo test --verbose --features all
- name: Test release
Expand All @@ -49,12 +44,32 @@ jobs:
- run: cargo build --no-default-features --features read_core,wasm
- run: cargo build --no-default-features --features doc

msrv-read:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install rust
run: rustup update 1.42.0 && rustup default 1.42.0
- name: Test
run: cargo test --verbose --no-default-features --features read,std

msrv-all:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install rust
run: rustup update 1.56.1 && rustup default 1.56.1
- name: Test
run: cargo test --verbose --features all

rustfmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install rustup
run: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile=minimal
- name: Install rust
run: |
rustup install stable
Expand All @@ -68,8 +83,6 @@ jobs:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install rustup
run: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile=minimal
- name: Install rust
run: |
rustup install stable
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ flate2 = { version = "1", optional = true }
indexmap = { version = "1.6", optional = true }
wasmparser = { version = "0.57", optional = true }
memchr = { version = "2.4.1", default-features = false }
hashbrown = { version = "0.11", features = ["ahash"], default-features = false, optional = true }
hashbrown = { version = "0.12.0", features = ["ahash"], default-features = false, optional = true }

# Internal feature, only used when building as part of libstd, not part of the
# stable interface of this crate.
Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,14 @@ fn main() -> Result<(), Box<dyn Error>> {

See [`crates/examples`](crates/examples) for more examples.

## Minimum Supported Rust Version (MSRV)

Changes to MSRV are considered breaking changes. We are conservative about changing the MSRV,
but sometimes are required to due to dependencies. The MSRV is:

* 1.42.0 for the `read` feature and its dependencies.
* 1.56.1 for the `write` feature and its dependencies.

## License

Licensed under either of
Expand Down
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
//!
//! /// Reads a file and displays the content of the ".boot" section.
//! fn main() -> Result<(), Box<dyn Error>> {
//! # #[cfg(feature = "read")] {
//! # #[cfg(all(feature = "read", feature = "std"))] {
//! let bin_data = fs::read("./multiboot2-binary.elf")?;
//! let obj_file = object::File::parse(&*bin_data)?;
//! if let Some(section) = obj_file.section_by_name(".boot") {
Expand Down