diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index d386aef5..47a0aae5 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -23,7 +23,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - toolchain: ["1.70.0", "stable", "nightly"] + toolchain: ["1.75.0", "stable", "nightly"] steps: - name: Checkout sources uses: actions/checkout@v4 diff --git a/Cargo.toml b/Cargo.toml index 1d15512c..0393240c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,7 +9,7 @@ keywords = ["bit", "bitmask", "bitflags", "flags"] categories = ["no-std"] repository = "https://github.com/GrayJack/bitflag-attr" homepage = "https://github.com/GrayJack/bitflag-attr" -rust-version = "1.70.0" +rust-version = "1.75.0" exclude = ["/tests", "/.github"] [lib] diff --git a/src/lib.rs b/src/lib.rs index b92c5269..4dcaf815 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -749,7 +749,7 @@ fn bitflag_impl(attr: TokenStream, item: TokenStream) -> Result { #debug_impl impl #ty_name { - const FLAGS: &[(&str, #ty_name)] = &[#((#all_flags_names , #all_flags) ,)*]; + const FLAGS: &'static [(&'static str, #ty_name)] = &[#((#all_flags_names , #all_flags) ,)*]; /// Yield a set of contained flags values. /// @@ -811,7 +811,7 @@ fn bitflag_impl(attr: TokenStream, item: TokenStream) -> Result { /// Helper for formatting in human readable format. Write a flags value as text, /// ignoring any unknown bits. - pub(crate) fn to_writer_truncate(&self, mut writer: W) -> ::core::fmt::Result + pub(crate) fn to_writer_truncate(&self, writer: W) -> ::core::fmt::Result where W: ::core::fmt::Write {