Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/bitflags/bitflags into bitf…
Browse files Browse the repository at this point in the history
…lags_trait
  • Loading branch information
arturoc committed Aug 23, 2021
2 parents 09e523e + a13bb56 commit b08e99f
Show file tree
Hide file tree
Showing 40 changed files with 1,101 additions and 531 deletions.
27 changes: 1 addition & 26 deletions .github/workflows/rust.yml
Expand Up @@ -16,7 +16,7 @@ jobs:
- stable
- beta
- nightly
- 1.32.0
- 1.46.0
steps:
- name: Checkout sources
uses: actions/checkout@v2
Expand Down Expand Up @@ -54,28 +54,3 @@ jobs:
with:
command: build
args: -Z avoid-dev-deps --features example_generated --target thumbv6m-none-eabi

suite:
name: Test suite
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
rust:
- nightly
steps:
- name: Checkout sources
uses: actions/checkout@v2

- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true

- name: Default features
uses: actions-rs/cargo@v1
with:
command: test
args: -p test_suite
1 change: 1 addition & 0 deletions .gitignore
@@ -1,3 +1,4 @@
wip
target
Cargo.lock

Expand Down
59 changes: 59 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,62 @@
# 1.3.2

- Allow `non_snake_case` in generated flags types ([#256])

[#256]: https://github.com/bitflags/bitflags/pull/256

# 1.3.1

- Revert unconditional `#[repr(transparent)]` ([#252])

[#252]: https://github.com/bitflags/bitflags/pull/252

# 1.3.0 (yanked)

**This release bumps the Minimum Supported Rust Version to `1.46.0`**

- Add `#[repr(transparent)]` ([#187])

- End `empty` doc comment with full stop ([#202])

- Fix typo in crate root docs ([#206])

- Document from_bits_unchecked unsafety ([#207])

- Let `is_all` ignore extra bits ([#211])

- Allows empty flag definition ([#225])

- Making crate accessible from std ([#227])

- Make `from_bits` a const fn ([#229])

- Allow multiple bitflags structs in one macro invocation ([#235])

- Add named functions to perform set operations ([#244])

- Fix typos in method docs ([#245])

- Modernization of the `bitflags` macro to take advantage of newer features and 2018 idioms ([#246])

- Fix regression (in an unreleased feature) and simplify tests ([#247])

- Use `Self` and fix bug when overriding `stringify!` ([#249])

[#187]: https://github.com/bitflags/bitflags/pull/187
[#202]: https://github.com/bitflags/bitflags/pull/202
[#206]: https://github.com/bitflags/bitflags/pull/206
[#207]: https://github.com/bitflags/bitflags/pull/207
[#211]: https://github.com/bitflags/bitflags/pull/211
[#225]: https://github.com/bitflags/bitflags/pull/225
[#227]: https://github.com/bitflags/bitflags/pull/227
[#229]: https://github.com/bitflags/bitflags/pull/229
[#235]: https://github.com/bitflags/bitflags/pull/235
[#244]: https://github.com/bitflags/bitflags/pull/244
[#245]: https://github.com/bitflags/bitflags/pull/245
[#246]: https://github.com/bitflags/bitflags/pull/246
[#247]: https://github.com/bitflags/bitflags/pull/247
[#249]: https://github.com/bitflags/bitflags/pull/249

# 1.2.1

- Remove extraneous `#[inline]` attributes ([#194])
Expand Down
23 changes: 12 additions & 11 deletions Cargo.toml
@@ -1,10 +1,10 @@
[package]

name = "bitflags"
# NB: When modifying, also modify:
# 1. html_root_url in lib.rs
# 2. number in readme (for breaking changes)
version = "1.2.1"
version = "1.3.2"
edition = "2018"
authors = ["The Rust Project Developers"]
license = "MIT/Apache-2.0"
keywords = ["bit", "bitmask", "bitflags", "flags"]
Expand All @@ -16,23 +16,24 @@ categories = ["no-std"]
description = """
A macro to generate structures which behave like bitflags.
"""
exclude = [
"appveyor.yml",
"bors.toml"
]
build = "build.rs"
exclude = ["bors.toml"]

[dependencies]
core = { version = '1.0.0', optional = true, package = 'rustc-std-workspace-core' }
compiler_builtins = { version = '0.1.2', optional = true }

[dev-dependencies]
trybuild = "1.0"
rustversion = "1.0"
walkdir = "2.3"
serde = "1.0"
serde_derive = "1.0"
serde_json = "1.0"

[features]
default = []
example_generated = []
rustc-dep-of-std = ["core", "compiler_builtins"]

[package.metadata.docs.rs]
features = [ "example_generated" ]

[workspace]
members = ["test_suite"]
features = ["example_generated"]
9 changes: 4 additions & 5 deletions README.md
Expand Up @@ -18,16 +18,15 @@ Add this to your `Cargo.toml`:

```toml
[dependencies]
bitflags = "1.2"
bitflags = "1.3"
```

and this to your crate root:
and this to your source code:

```rust
#[macro_use]
extern crate bitflags;
use bitflags::bitflags;
```

## Rust Version Support

The minimum supported Rust version is 1.20 due to use of associated constants.
The minimum supported Rust version is 1.46 due to use of associated constants and const functions.
44 changes: 0 additions & 44 deletions build.rs

This file was deleted.

0 comments on commit b08e99f

Please sign in to comment.