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

errors compiling on latest rust / fedora 40 #313

Open
NeilHanlon opened this issue Dec 17, 2024 · 0 comments
Open

errors compiling on latest rust / fedora 40 #313

NeilHanlon opened this issue Dec 17, 2024 · 0 comments

Comments

@NeilHanlon
Copy link

Heya - I went to rebuild some containers I have and found messages like the following:

error: lint `box_pointers` has been removed: it does not detect other kinds of allocations, and existed only for historical reasons
  --> src/bin/common/protos/mirrormanager.rs:10:10
   |
10 | #![allow(box_pointers)]
   |          ^^^^^^^^^^^^
   |
note: the lint level is defined here
  --> src/bin/mirrorlist-server.rs:1:9
   |
1  | #![deny(warnings)]
   |         ^^^^^^^^
   = note: `#[deny(renamed_and_removed_lints)]` implied by `#[deny(warnings)]`

error: lint `box_pointers` has been removed: it does not detect other kinds of allocations, and existed only for historical reasons
  --> src/bin/common/protos/mirrormanager.rs:10:10
   |
10 | #![allow(box_pointers)]
   |          ^^^^^^^^^^^^
   |
note: the lint level is defined here
  --> src/bin/generate-mirrorlist-cache.rs:1:9
   |
1  | #![deny(warnings)]
   |         ^^^^^^^^
   = note: `#[deny(renamed_and_removed_lints)]` implied by `#[deny(warnings)]`

and


error: creating a mutable reference to mutable static is discouraged
   --> src/bin/common/protos/mirrormanager.rs:369:13
    |
369 | /             descriptor.get(|| {
370 | |                 let mut fields = ::std::vec::Vec::new();
371 | |                 fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
372 | |                     "TimeStamp",
...   |
405 | |                 )
406 | |             })
    | |______________^ mutable reference to mutable static
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/static-mut-references.html>
    = note: mutable references to mutable statics are dangerous; it's undefined behavior if any other pointer to the static is used or if any other reference is created for the static while the mutable reference lives
    = note: `#[deny(static_mut_refs)]` implied by `#[deny(warnings)]`

error: creating a mutable reference to mutable static is discouraged
   --> src/bin/common/protos/mirrormanager.rs:413:13
    |
413 |             instance.get(FileDetailsType::new)
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ mutable reference to mutable static
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/static-mut-references.html>
    = note: mutable references to mutable statics are dangerous; it's undefined behavior if any other pointer to the static is used or if any other reference is created for the static while the mutable reference lives

<snip>

error: creating a mutable reference to mutable static is discouraged
    --> src/bin/common/protos/mirrormanager.rs:3800:9
     |
3800 | /         file_descriptor_proto_lazy.get(|| {
3801 | |             parse_descriptor_proto()
3802 | |         })
     | |__________^ mutable reference to mutable static
     |
     = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/static-mut-references.html>
     = note: mutable references to mutable statics are dangerous; it's undefined behavior if any other pointer to the static is used or if any other reference is created for the static while the mutable reference lives

Seems like some standard rust... stuff... :) Let me know if/how I can help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant