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

Tracking Issue for RFC 3484: Unsafe Extern Blocks #123743

Closed
10 tasks done
traviscross opened this issue Apr 10, 2024 · 10 comments
Closed
10 tasks done

Tracking Issue for RFC 3484: Unsafe Extern Blocks #123743

traviscross opened this issue Apr 10, 2024 · 10 comments
Assignees
Labels
A-edition-2024 Area: The 2024 edition B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC F-unsafe_extern_blocks `#![feature(unsafe_extern_blocks)]` S-tracking-ready-for-edition Status: This issue is ready for inclusion in the edition. T-lang Relevant to the language team, which will review and decide on the PR/issue.

Comments

@traviscross
Copy link
Contributor

traviscross commented Apr 10, 2024

This is a tracking issue for the RFC 3484: Unsafe Extern Blocks

RFC: rust-lang/rfcs#3484
Issues: F-unsafe_extern_blocks `#![feature(unsafe_extern_blocks)]`

The feature gate for the issue is #![feature(unsafe_extern_blocks)].

About tracking issues

Tracking issues are used to record the overall progress of implementation. They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions. A tracking issue is however not meant for large scale discussion, questions, or bug reports about a feature. Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.

Steps

Related

cc @Lokathor @spastorino

@traviscross traviscross added C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC T-lang Relevant to the language team, which will review and decide on the PR/issue. A-edition-2024 Area: The 2024 edition labels Apr 10, 2024
@oli-obk
Copy link
Contributor

oli-obk commented Apr 29, 2024

I have been reviewing some work (and the required refactorings), and the refactorings need refactorings of their own (not sure how many layers of turtles are needed, but it's not all the way down) 😓

The only way to get it done in time is to not do refactorings before, but just leave FIXMEs, which doesn't sit right with me. So:

let's not do this for the 2024 edition, but jump straight into implementing the 2027 edition

@oli-obk oli-obk added A-edition-2027 Area: The 2027 edition (TBD) and removed A-edition-2024 Area: The 2024 edition labels Apr 29, 2024
@traviscross traviscross added F-unsafe_extern_blocks `#![feature(unsafe_extern_blocks)]` B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. labels May 6, 2024
@traviscross traviscross added S-tracking-impl-incomplete Status: The implementation is incomplete. S-tracking-needs-migration-lint Status: This item needs a migration lint. S-tracking-needs-documentation Status: Needs documentation. labels May 21, 2024
@traviscross
Copy link
Contributor Author

@rustbot labels -A-edition-2027 +A-edition-2024

Based on the fact that it seems #124482 is likely to land in time, let's retarget this for Rust 2024 for now.

@rustbot rustbot added A-edition-2024 Area: The 2024 edition and removed A-edition-2027 Area: The 2027 edition (TBD) labels Jun 4, 2024
@traviscross traviscross removed the S-tracking-needs-migration-lint Status: This item needs a migration lint. label Jun 4, 2024
bors added a commit to rust-lang-ci/rust that referenced this issue Jun 6, 2024
…li-obk

Unsafe extern blocks

This implements RFC 3484.

Tracking issue rust-lang#123743 and RFC rust-lang/rfcs#3484

This is better reviewed commit by commit.
@traviscross traviscross removed the S-tracking-impl-incomplete Status: The implementation is incomplete. label Jun 11, 2024
@traviscross
Copy link
Contributor Author

@rustbot labels +I-style-nominated

Let's nominate to discuss this for visibility on the style side. One style-related question here would be whether we want rustfmt to have an opinion about whether items within an unsafe extern block should be explicitly prefixed with unsafe if not otherwise qualified.

@rustbot rustbot added the I-style-nominated Nominated for discussion during a style team meeting. label Jun 11, 2024
@traviscross traviscross added the S-tracking-ready-to-stabilize Status: This is ready to stabilize; it may need a stabilization report and a PR label Jun 11, 2024
flip1995 pushed a commit to flip1995/rust that referenced this issue Jun 13, 2024
…li-obk

Unsafe extern blocks

This implements RFC 3484.

Tracking issue rust-lang#123743 and RFC rust-lang/rfcs#3484

This is better reviewed commit by commit.
@ehuss
Copy link
Contributor

ehuss commented Jun 20, 2024

Edition docs are up at rust-lang/edition-guide#309.

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Jun 20, 2024
Properly gate `safe` keyword in pre-expansion

This PR gates `safe` keyword in pre-expansion contexts. Should mitigate the fallout of rust-lang#126755, which is that `safe` is now usable on beta lol.

r? `@spastorino` or `@oli-obk`

cc rust-lang#124482 tracking rust-lang#123743
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Jun 26, 2024
Rollup merge of rust-lang#126973 - chenyukang:yukang-fix-126756-unsafe-suggestion-error, r=spastorino

Fix bad replacement for unsafe extern block suggestion

Fixes rust-lang#126756

r? ``@spastorino``

link rust-lang#123743
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Jun 29, 2024
…locks-diagnostics, r=compiler-errors

Improve unsafe extern blocks diagnostics

Closes rust-lang#126327

For this code:

```rust
extern {
    pub fn foo();
    pub safe fn bar();
}
```

We get ...

```
error: items in unadorned `extern` blocks cannot have safety qualifiers
 --> test.rs:3:5
  |
3 |     pub safe fn bar();
  |     ^^^^^^^^^^^^^^^^^^
  |
help: add unsafe to this `extern` block
  |
1 | unsafe extern {
  | ++++++

error[E0658]: `unsafe extern {}` blocks and `safe` keyword are experimental
 --> test.rs:3:9
  |
3 |     pub safe fn bar();
  |         ^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0658`.
```

And then making the extern block unsafe, we get ...

```
error: extern block cannot be declared unsafe
 --> test.rs:1:1
  |
1 | unsafe extern {
  | ^^^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: items in unadorned `extern` blocks cannot have safety qualifiers
 --> test.rs:3:5
  |
3 |     pub safe fn bar();
  |     ^^^^^^^^^^^^^^^^^^

error[E0658]: `unsafe extern {}` blocks and `safe` keyword are experimental
 --> test.rs:3:9
  |
3 |     pub safe fn bar();
  |         ^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: aborting due to 3 previous errors

For more information about this error, try `rustc --explain E0658`.
```

r? `@compiler-errors`
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Jun 29, 2024
…locks-diagnostics, r=compiler-errors

Improve unsafe extern blocks diagnostics

Closes rust-lang#126327

For this code:

```rust
extern {
    pub fn foo();
    pub safe fn bar();
}
```

We get ...

```
error: items in unadorned `extern` blocks cannot have safety qualifiers
 --> test.rs:3:5
  |
3 |     pub safe fn bar();
  |     ^^^^^^^^^^^^^^^^^^
  |
help: add unsafe to this `extern` block
  |
1 | unsafe extern {
  | ++++++

error[E0658]: `unsafe extern {}` blocks and `safe` keyword are experimental
 --> test.rs:3:9
  |
3 |     pub safe fn bar();
  |         ^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0658`.
```

And then making the extern block unsafe, we get ...

```
error: extern block cannot be declared unsafe
 --> test.rs:1:1
  |
1 | unsafe extern {
  | ^^^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: items in unadorned `extern` blocks cannot have safety qualifiers
 --> test.rs:3:5
  |
3 |     pub safe fn bar();
  |     ^^^^^^^^^^^^^^^^^^

error[E0658]: `unsafe extern {}` blocks and `safe` keyword are experimental
 --> test.rs:3:9
  |
3 |     pub safe fn bar();
  |         ^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: aborting due to 3 previous errors

For more information about this error, try `rustc --explain E0658`.
```

r? ``@compiler-errors``
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Jun 30, 2024
Rollup merge of rust-lang#127106 - spastorino:improve-unsafe-extern-blocks-diagnostics, r=compiler-errors

Improve unsafe extern blocks diagnostics

Closes rust-lang#126327

For this code:

```rust
extern {
    pub fn foo();
    pub safe fn bar();
}
```

We get ...

```
error: items in unadorned `extern` blocks cannot have safety qualifiers
 --> test.rs:3:5
  |
3 |     pub safe fn bar();
  |     ^^^^^^^^^^^^^^^^^^
  |
help: add unsafe to this `extern` block
  |
1 | unsafe extern {
  | ++++++

error[E0658]: `unsafe extern {}` blocks and `safe` keyword are experimental
 --> test.rs:3:9
  |
3 |     pub safe fn bar();
  |         ^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0658`.
```

And then making the extern block unsafe, we get ...

```
error: extern block cannot be declared unsafe
 --> test.rs:1:1
  |
1 | unsafe extern {
  | ^^^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: items in unadorned `extern` blocks cannot have safety qualifiers
 --> test.rs:3:5
  |
3 |     pub safe fn bar();
  |     ^^^^^^^^^^^^^^^^^^

error[E0658]: `unsafe extern {}` blocks and `safe` keyword are experimental
 --> test.rs:3:9
  |
3 |     pub safe fn bar();
  |         ^^^^
  |
  = note: see issue rust-lang#123743 <rust-lang#123743> for more information
  = help: add `#![feature(unsafe_extern_blocks)]` to the crate attributes to enable

error: aborting due to 3 previous errors

For more information about this error, try `rustc --explain E0658`.
```

r? ``@compiler-errors``
@traviscross traviscross removed the S-tracking-needs-documentation Status: Needs documentation. label Jul 21, 2024
tgross35 added a commit to tgross35/rust that referenced this issue Aug 3, 2024
…-blocks, r=compiler-errors

Stabilize unsafe extern blocks (RFC 3484)

# Stabilization report

## Summary

This is a tracking issue for the RFC 3484: Unsafe Extern Blocks

We are stabilizing `#![feature(unsafe_extern_blocks)]`, as described in [Unsafe Extern Blocks RFC 3484](rust-lang/rfcs#3484). This feature makes explicit that declaring an extern block is unsafe. Starting in Rust 2024, all extern blocks must be marked as unsafe. In all editions, items within unsafe extern blocks may be marked as safe to use.

RFC: rust-lang/rfcs#3484
Tracking issue: rust-lang#123743

## What is stabilized

### Summary of stabilization

We now need extern blocks to be marked as unsafe and items inside can also have safety modifiers (unsafe or safe), by default items with no modifiers are unsafe to offer easy migration without surprising results.

```rust
unsafe extern {
    // sqrt (from libm) may be called with any `f64`
    pub safe fn sqrt(x: f64) -> f64;

    // strlen (from libc) requires a valid pointer,
    // so we mark it as being an unsafe fn
    pub unsafe fn strlen(p: *const c_char) -> usize;

    // this function doesn't say safe or unsafe, so it defaults to unsafe
    pub fn free(p: *mut core::ffi::c_void);

    pub safe static IMPORTANT_BYTES: [u8; 256];

    pub safe static LINES: SyncUnsafeCell<i32>;
}
```

## Tests

The relevant tests are in `tests/ui/rust-2024/unsafe-extern-blocks`.

## History

- rust-lang#124482
- rust-lang#124455
- rust-lang#125077
- rust-lang#125522
- rust-lang#126738
- rust-lang#126749
- rust-lang#126755
- rust-lang#126757
- rust-lang#126758
- rust-lang#126756
- rust-lang#126973
- rust-lang#127535
- rust-lang/rustfmt#6204

## Unresolved questions

I am not aware of any unresolved questions.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Aug 3, 2024
…-blocks, r=compiler-errors

Stabilize unsafe extern blocks (RFC 3484)

# Stabilization report

## Summary

This is a tracking issue for the RFC 3484: Unsafe Extern Blocks

We are stabilizing `#![feature(unsafe_extern_blocks)]`, as described in [Unsafe Extern Blocks RFC 3484](rust-lang/rfcs#3484). This feature makes explicit that declaring an extern block is unsafe. Starting in Rust 2024, all extern blocks must be marked as unsafe. In all editions, items within unsafe extern blocks may be marked as safe to use.

RFC: rust-lang/rfcs#3484
Tracking issue: rust-lang#123743

## What is stabilized

### Summary of stabilization

We now need extern blocks to be marked as unsafe and items inside can also have safety modifiers (unsafe or safe), by default items with no modifiers are unsafe to offer easy migration without surprising results.

```rust
unsafe extern {
    // sqrt (from libm) may be called with any `f64`
    pub safe fn sqrt(x: f64) -> f64;

    // strlen (from libc) requires a valid pointer,
    // so we mark it as being an unsafe fn
    pub unsafe fn strlen(p: *const c_char) -> usize;

    // this function doesn't say safe or unsafe, so it defaults to unsafe
    pub fn free(p: *mut core::ffi::c_void);

    pub safe static IMPORTANT_BYTES: [u8; 256];

    pub safe static LINES: SyncUnsafeCell<i32>;
}
```

## Tests

The relevant tests are in `tests/ui/rust-2024/unsafe-extern-blocks`.

## History

- rust-lang#124482
- rust-lang#124455
- rust-lang#125077
- rust-lang#125522
- rust-lang#126738
- rust-lang#126749
- rust-lang#126755
- rust-lang#126757
- rust-lang#126758
- rust-lang#126756
- rust-lang#126973
- rust-lang#127535
- rust-lang/rustfmt#6204

## Unresolved questions

I am not aware of any unresolved questions.
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Aug 3, 2024
Rollup merge of rust-lang#127921 - spastorino:stabilize-unsafe-extern-blocks, r=compiler-errors

Stabilize unsafe extern blocks (RFC 3484)

# Stabilization report

## Summary

This is a tracking issue for the RFC 3484: Unsafe Extern Blocks

We are stabilizing `#![feature(unsafe_extern_blocks)]`, as described in [Unsafe Extern Blocks RFC 3484](rust-lang/rfcs#3484). This feature makes explicit that declaring an extern block is unsafe. Starting in Rust 2024, all extern blocks must be marked as unsafe. In all editions, items within unsafe extern blocks may be marked as safe to use.

RFC: rust-lang/rfcs#3484
Tracking issue: rust-lang#123743

## What is stabilized

### Summary of stabilization

We now need extern blocks to be marked as unsafe and items inside can also have safety modifiers (unsafe or safe), by default items with no modifiers are unsafe to offer easy migration without surprising results.

```rust
unsafe extern {
    // sqrt (from libm) may be called with any `f64`
    pub safe fn sqrt(x: f64) -> f64;

    // strlen (from libc) requires a valid pointer,
    // so we mark it as being an unsafe fn
    pub unsafe fn strlen(p: *const c_char) -> usize;

    // this function doesn't say safe or unsafe, so it defaults to unsafe
    pub fn free(p: *mut core::ffi::c_void);

    pub safe static IMPORTANT_BYTES: [u8; 256];

    pub safe static LINES: SyncUnsafeCell<i32>;
}
```

## Tests

The relevant tests are in `tests/ui/rust-2024/unsafe-extern-blocks`.

## History

- rust-lang#124482
- rust-lang#124455
- rust-lang#125077
- rust-lang#125522
- rust-lang#126738
- rust-lang#126749
- rust-lang#126755
- rust-lang#126757
- rust-lang#126758
- rust-lang#126756
- rust-lang#126973
- rust-lang#127535
- rust-lang/rustfmt#6204

## Unresolved questions

I am not aware of any unresolved questions.
@traviscross
Copy link
Contributor Author

@rustbot labels -S-tracking-ready-to-stabilize +S-tracking-ready-for-edition

With the merge of #127921, this item is now ready for Rust 2024.

Thanks to @spastorino for pushing this important work to completion.

@rustbot rustbot added S-tracking-ready-for-edition Status: This issue is ready for inclusion in the edition. and removed S-tracking-ready-to-stabilize Status: This is ready to stabilize; it may need a stabilization report and a PR labels Aug 4, 2024
@traviscross traviscross removed the I-style-nominated Nominated for discussion during a style team meeting. label Aug 4, 2024
workingjubilee added a commit to workingjubilee/rustc that referenced this issue Aug 27, 2024
…-style-guide, r=compiler-errors

Add unsafe to extern blocks in style guide

This goes after this is merged:

- rust-lang#127921

r? `@traviscross`

Tracking:

- rust-lang#123743
tgross35 added a commit to tgross35/rust that referenced this issue Aug 27, 2024
…-style-guide, r=compiler-errors

Add unsafe to extern blocks in style guide

This goes after this is merged:

- rust-lang#127921

r? ``@traviscross``

Tracking:

- rust-lang#123743
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Aug 27, 2024
Rollup merge of rust-lang#127922 - spastorino:unsafe-extern-blocks-in-style-guide, r=compiler-errors

Add unsafe to extern blocks in style guide

This goes after this is merged:

- rust-lang#127921

r? ``@traviscross``

Tracking:

- rust-lang#123743
github-actions bot pushed a commit to rust-lang/miri that referenced this issue Aug 28, 2024
…ide, r=compiler-errors

Add unsafe to extern blocks in style guide

This goes after this is merged:

- rust-lang/rust#127921

r? ``@traviscross``

Tracking:

- rust-lang/rust#123743
bors added a commit to rust-lang-ci/rust that referenced this issue Oct 11, 2024
…r=GuillaumeGomez

rustdoc-json: Add tests for unsafe/safe extern blocks (RFC 3484)

Closes rust-lang#126786, turns out this all Just Works (TM)

Tracking issue: rust-lang#123743

r? `@GuillaumeGomez`
dtolnay added a commit to dtolnay/cxx that referenced this issue Nov 12, 2024
    warning: unsafe attribute used without unsafe
      --> tests/ffi/module.rs:15:19
       |
    15 |     impl Vec<Job> {}
       |                   ^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    note: the lint level is defined here
      --> tests/ffi/lib.rs:18:9
       |
    18 | #![warn(rust_2024_compatibility)]
       |         ^^^^^^^^^^^^^^^^^^^^^^^
       = note: `#[warn(unsafe_attr_outside_unsafe)]` implied by `#[warn(rust_2024_compatibility)]`
    help: wrap the attribute in `unsafe(...)`
       |
    15 |     impl Vec<Job> {unsafe(})
       |                    +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:171:58
        |
    171 |         fn c_take_callback(callback: fn(String) -> usize);
        |                                                          ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    171 |         fn c_take_callback(callback: fn(String) -> usize)unsafe(;)
        |                                                          +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:172:54
        |
    172 |         fn c_take_callback_ref(callback: fn(&String));
        |                                                      ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    172 |         fn c_take_callback_ref(callback: fn(&String))unsafe(;)
        |                                                      +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:174:70
        |
    174 |         fn c_take_callback_ref_lifetime<'a>(callback: fn(&'a String));
        |                                                                      ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    174 |         fn c_take_callback_ref_lifetime<'a>(callback: fn(&'a String))unsafe(;)
        |                                                                      +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:175:58
        |
    175 |         fn c_take_callback_mut(callback: fn(&mut String));
        |                                                          ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    175 |         fn c_take_callback_mut(callback: fn(&mut String))unsafe(;)
        |                                                          +++++++ +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:31:28
       |
    31 |     #[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord)]
       |                            ^^^^^^^^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    31 |     #[derive(Clone, Debug, Paunsafe(rtialE)q, Eq, PartialOrd, Ord)]
       |                              +++++++      +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:31:43
       |
    31 |     #[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord)]
       |                                           ^^^^^^^^^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    31 |     #[derive(Clone, Debug, PartialEq, Eq, Paunsafe(rtialOr)d, Ord)]
       |                                             +++++++       +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:36:14
       |
    36 |     #[derive(PartialEq, PartialOrd)]
       |              ^^^^^^^^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    36 |     #[derive(Paunsafe(rtialE)q, PartialOrd)]
       |                +++++++      +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:36:25
       |
    36 |     #[derive(PartialEq, PartialOrd)]
       |                         ^^^^^^^^^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    36 |     #[derive(PartialEq, Paunsafe(rtialOr)d)]
       |                           +++++++       +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:82:14
       |
    82 |     #[derive(Hash)]
       |              ^^^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    82 |     #[derive(Haunsafe(s)h)]
       |                +++++++ +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:93:47
       |
    93 |     #[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)]
       |                                               ^^^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    93 |     #[derive(Copy, Clone, Debug, Default, Eq, Haunsafe(s)h, Ord, PartialEq, PartialOrd)]
       |                                                 +++++++ +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:93:58
       |
    93 |     #[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)]
       |                                                          ^^^^^^^^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    93 |     #[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, Paunsafe(rtialE)q, PartialOrd)]
       |                                                            +++++++      +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:93:69
       |
    93 |     #[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)]
       |                                                                     ^^^^^^^^^^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    93 |     #[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, Paunsafe(rtialOr)d)]
       |                                                                       +++++++       +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:236:14
        |
    236 |         type Reference<'a>;
        |              ^^^^^^^^^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    236 |         type Reunsafe(ferenc)e<'a>;
        |                +++++++      +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:265:14
        |
    265 |         type R;
        |              ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    265 |         type unsafe(R);
        |              +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:267:41
        |
    267 |         fn r_return_primitive() -> usize;
        |                                         ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    267 |         fn r_return_primitive() -> usizeunsafe(;)
        |                                         +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:268:39
        |
    268 |         fn r_return_shared() -> Shared;
        |                                       ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    268 |         fn r_return_shared() -> Sharedunsafe(;)
        |                                       +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:269:36
        |
    269 |         fn r_return_box() -> Box<R>;
        |                                    ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    269 |         fn r_return_box() -> Box<R>unsafe(;)
        |                                    +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:270:49
        |
    270 |         fn r_return_unique_ptr() -> UniquePtr<C>;
        |                                                 ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    270 |         fn r_return_unique_ptr() -> UniquePtr<C>unsafe(;)
        |                                                 +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:271:49
        |
    271 |         fn r_return_shared_ptr() -> SharedPtr<C>;
        |                                                 ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    271 |         fn r_return_shared_ptr() -> SharedPtr<C>unsafe(;)
        |                                                 +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:272:51
        |
    272 |         fn r_return_ref(shared: &Shared) -> &usize;
        |                                                   ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    272 |         fn r_return_ref(shared: &Shared) -> &usizeunsafe(;)
        |                                                   +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:273:59
        |
    273 |         fn r_return_mut(shared: &mut Shared) -> &mut usize;
        |                                                           ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    273 |         fn r_return_mut(shared: &mut Shared) -> &mut usizeunsafe(;)
        |                                                           +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:274:49
        |
    274 |         fn r_return_str(shared: &Shared) -> &str;
        |                                                 ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    274 |         fn r_return_str(shared: &Shared) -> &strunsafe(;)
        |                                                 +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:275:54
        |
    275 |         fn r_return_sliceu8(shared: &Shared) -> &[u8];
        |                                                      ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    275 |         fn r_return_sliceu8(shared: &Shared) -> &[u8]unsafe(;)
        |                                                      +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:276:62
        |
    276 |         fn r_return_mutsliceu8(slice: &mut [u8]) -> &mut [u8];
        |                                                              ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    276 |         fn r_return_mutsliceu8(slice: &mut [u8]) -> &mut [u8]unsafe(;)
        |                                                              +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:277:44
        |
    277 |         fn r_return_rust_string() -> String;
        |                                            ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    277 |         fn r_return_rust_string() -> Stringunsafe(;)
        |                                            +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:278:64
        |
    278 |         fn r_return_unique_ptr_string() -> UniquePtr<CxxString>;
        |                                                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    278 |         fn r_return_unique_ptr_string() -> UniquePtr<CxxString>unsafe(;)
        |                                                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:279:42
        |
    279 |         fn r_return_rust_vec() -> Vec<u8>;
        |                                          ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    279 |         fn r_return_rust_vec() -> Vec<u8>unsafe(;)
        |                                          +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:280:53
        |
    280 |         fn r_return_rust_vec_string() -> Vec<String>;
        |                                                     ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    280 |         fn r_return_rust_vec_string() -> Vec<String>unsafe(;)
        |                                                     +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:281:57
        |
    281 |         fn r_return_rust_vec_extern_struct() -> Vec<Job>;
        |                                                         ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    281 |         fn r_return_rust_vec_extern_struct() -> Vec<Job>unsafe(;)
        |                                                         +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:282:62
        |
    282 |         fn r_return_ref_rust_vec(shared: &Shared) -> &Vec<u8>;
        |                                                              ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    282 |         fn r_return_ref_rust_vec(shared: &Shared) -> &Vec<u8>unsafe(;)
        |                                                              +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:283:70
        |
    283 |         fn r_return_mut_rust_vec(shared: &mut Shared) -> &mut Vec<u8>;
        |                                                                      ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    283 |         fn r_return_mut_rust_vec(shared: &mut Shared) -> &mut Vec<u8>unsafe(;)
        |                                                                      +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:284:48
        |
    284 |         fn r_return_identity(_: usize) -> usize;
        |                                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    284 |         fn r_return_identity(_: usize) -> usizeunsafe(;)
        |                                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:285:53
        |
    285 |         fn r_return_sum(_: usize, _: usize) -> usize;
        |                                                     ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    285 |         fn r_return_sum(_: usize, _: usize) -> usizeunsafe(;)
        |                                                     +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:286:41
        |
    286 |         fn r_return_enum(n: u32) -> Enum;
        |                                         ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    286 |         fn r_return_enum(n: u32) -> Enumunsafe(;)
        |                                         +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:288:38
        |
    288 |         fn r_take_primitive(n: usize);
        |                                      ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    288 |         fn r_take_primitive(n: usize)unsafe(;)
        |                                      +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:289:41
        |
    289 |         fn r_take_shared(shared: Shared);
        |                                         ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    289 |         fn r_take_shared(shared: Shared)unsafe(;)
        |                                         +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:290:33
        |
    290 |         fn r_take_box(r: Box<R>);
        |                                 ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    290 |         fn r_take_box(r: Box<R>)unsafe(;)
        |                                 +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:291:46
        |
    291 |         fn r_take_unique_ptr(c: UniquePtr<C>);
        |                                              ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    291 |         fn r_take_unique_ptr(c: UniquePtr<C>)unsafe(;)
        |                                              +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:292:46
        |
    292 |         fn r_take_shared_ptr(c: SharedPtr<C>);
        |                                              ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    292 |         fn r_take_shared_ptr(c: SharedPtr<C>)unsafe(;)
        |                                              +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:293:31
        |
    293 |         fn r_take_ref_r(r: &R);
        |                               ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    293 |         fn r_take_ref_r(r: &R)unsafe(;)
        |                               +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:294:31
        |
    294 |         fn r_take_ref_c(c: &C);
        |                               ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    294 |         fn r_take_ref_c(c: &C)unsafe(;)
        |                               +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:295:31
        |
    295 |         fn r_take_str(s: &str);
        |                               ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    295 |         fn r_take_str(s: &str)unsafe(;)
        |                               +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:296:43
        |
    296 |         fn r_take_slice_char(s: &[c_char]);
        |                                           ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    296 |         fn r_take_slice_char(s: &[c_char])unsafe(;)
        |                                           +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:297:41
        |
    297 |         fn r_take_rust_string(s: String);
        |                                         ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    297 |         fn r_take_rust_string(s: String)unsafe(;)
        |                                         +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:298:61
        |
    298 |         fn r_take_unique_ptr_string(s: UniquePtr<CxxString>);
        |                                                             ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    298 |         fn r_take_unique_ptr_string(s: UniquePtr<CxxString>)unsafe(;)
        |                                                             +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:299:48
        |
    299 |         fn r_take_ref_vector(v: &CxxVector<u8>);
        |                                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    299 |         fn r_take_ref_vector(v: &CxxVector<u8>)unsafe(;)
        |                                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:300:55
        |
    300 |         fn r_take_ref_empty_vector(v: &CxxVector<u64>);
        |                                                       ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    300 |         fn r_take_ref_empty_vector(v: &CxxVector<u64>)unsafe(;)
        |                                                       +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:301:39
        |
    301 |         fn r_take_rust_vec(v: Vec<u8>);
        |                                       ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    301 |         fn r_take_rust_vec(v: Vec<u8>)unsafe(;)
        |                                       +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:302:50
        |
    302 |         fn r_take_rust_vec_string(v: Vec<String>);
        |                                                  ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    302 |         fn r_take_rust_vec_string(v: Vec<String>)unsafe(;)
        |                                                  +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:303:44
        |
    303 |         fn r_take_ref_rust_vec(v: &Vec<u8>);
        |                                            ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    303 |         fn r_take_ref_rust_vec(v: &Vec<u8>)unsafe(;)
        |                                            +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:304:55
        |
    304 |         fn r_take_ref_rust_vec_string(v: &Vec<String>);
        |                                                       ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    304 |         fn r_take_ref_rust_vec_string(v: &Vec<String>)unsafe(;)
        |                                                       +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:305:32
        |
    305 |         fn r_take_enum(e: Enum);
        |                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    305 |         fn r_take_enum(e: Enum)unsafe(;)
        |                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:307:45
        |
    307 |         fn r_try_return_void() -> Result<()>;
        |                                             ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    307 |         fn r_try_return_void() -> Result<()>unsafe(;)
        |                                             +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:308:53
        |
    308 |         fn r_try_return_primitive() -> Result<usize>;
        |                                                     ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    308 |         fn r_try_return_primitive() -> Result<usize>unsafe(;)
        |                                                     +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:309:48
        |
    309 |         fn r_try_return_box() -> Result<Box<R>>;
        |                                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    309 |         fn r_try_return_box() -> Result<Box<R>>unsafe(;)
        |                                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:310:54
        |
    310 |         fn r_fail_return_primitive() -> Result<usize>;
        |                                                      ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    310 |         fn r_fail_return_primitive() -> Result<usize>unsafe(;)
        |                                                      +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:311:59
        |
    311 |         fn r_try_return_sliceu8(s: &[u8]) -> Result<&[u8]>;
        |                                                           ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    311 |         fn r_try_return_sliceu8(s: &[u8]) -> Result<&[u8]>unsafe(;)
        |                                                           +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:312:70
        |
    312 |         fn r_try_return_mutsliceu8(s: &mut [u8]) -> Result<&mut [u8]>;
        |                                                                      ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    312 |         fn r_try_return_mutsliceu8(s: &mut [u8]) -> Result<&mut [u8]>unsafe(;)
        |                                                                      +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:314:34
        |
    314 |         fn get(self: &R) -> usize;
        |                                  ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    314 |         fn get(self: &R) -> usizeunsafe(;)
        |                                  +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:315:48
        |
    315 |         fn set(self: &mut R, n: usize) -> usize;
        |                                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    315 |         fn set(self: &mut R, n: usize) -> usizeunsafe(;)
        |                                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:316:55
        |
    316 |         fn r_method_on_shared(self: &Shared) -> String;
        |                                                       ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    316 |         fn r_method_on_shared(self: &Shared) -> Stringunsafe(;)
        |                                                       +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:317:48
        |
    317 |         fn r_get_array_sum(self: &Array) -> i32;
        |                                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    317 |         fn r_get_array_sum(self: &Array) -> i32unsafe(;)
        |                                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:320:48
        |
    320 |         fn r_aliased_function(x: i32) -> String;
        |                                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    320 |         fn r_aliased_function(x: i32) -> Stringunsafe(;)
        |                                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:344:22
        |
    344 |     impl Box<Shared> {}
        |                      ^^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    344 |     impl Box<Shared> {unsafe(})
        |                       +++++++ +

    warning: unsafe attribute used without unsafe
      --> tests/ffi/lib.rs:78:27
       |
    78 |         second: Box<Second>,
       |                           ^ usage of unsafe attribute
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
       |
    78 |         second: Box<Secondunsafe(>),
       |                           +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:105:35
        |
    105 |         fn c_return_box() -> Box<R>;
        |                                   ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    105 |         fn c_return_box() -> Box<Runsafe(>);
        |                                   +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:157:48
        |
    157 |         fn c_take_rust_vec_shared(v: Vec<Shared>);
        |                                                ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    157 |         fn c_take_rust_vec_shared(v: Vec<Sharedunsafe(>));
        |                                                +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:181:52
        |
    181 |         fn c_take_rust_vec_ns_shared(v: Vec<AShared>);
        |                                                    ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    181 |         fn c_take_rust_vec_ns_shared(v: Vec<ASharedunsafe(>));
        |                                                    +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:182:60
        |
    182 |         fn c_take_rust_vec_nested_ns_shared(v: Vec<ABShared>);
        |                                                            ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    182 |         fn c_take_rust_vec_nested_ns_shared(v: Vec<ABSharedunsafe(>));
        |                                                            +++++++ +

    warning: unsafe attribute used without unsafe
       --> tests/ffi/lib.rs:329:22
        |
    329 |         vec: Vec<Dag3>,
        |                      ^ usage of unsafe attribute
        |
        = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
        = note: for more information, see issue #123757 <https://github.com/rust-lang/rust/issues/123757>
    help: wrap the attribute in `unsafe(...)`
        |
    329 |         vec: Vec<Dag3unsafe(>),
        |                      +++++++ +

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:12:46
       |
    12 |         fn c_take_unique_ptr(c: UniquePtr<C>);
       |                                              ^
       |                                              |
       |                                              help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>
       = note: `#[warn(missing_unsafe_on_extern)]` implied by `#[warn(rust_2024_compatibility)]`

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:33:47
       |
    33 |         fn c_take_trivial_ptr(d: UniquePtr<D>);
       |                                               ^
       |                                               |
       |                                               help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:34:37
       |
    34 |         fn c_take_trivial_ref(d: &D);
       |                                     ^
       |                                     |
       |                                     help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:35:45
       |
    35 |         fn c_take_trivial_mut_ref(d: &mut D);
       |                                             ^
       |                                             |
       |                                             help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:36:46
       |
    36 |         fn c_take_trivial_pin_ref(d: Pin<&D>);
       |                                              ^
       |                                              |
       |                                              help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:37:54
       |
    37 |         fn c_take_trivial_pin_mut_ref(d: Pin<&mut D>);
       |                                                      ^
       |                                                      |
       |                                                      help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:38:47
       |
    38 |         fn c_take_trivial_ref_method(self: &D);
       |                                               ^
       |                                               |
       |                                               help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:39:55
       |
    39 |         fn c_take_trivial_mut_ref_method(self: &mut D);
       |                                                       ^
       |                                                       |
       |                                                       help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:40:32
       |
    40 |         fn c_take_trivial(d: D);
       |                                ^
       |                                |
       |                                help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:41:50
       |
    41 |         fn c_take_trivial_ns_ptr(g: UniquePtr<G>);
       |                                                  ^
       |                                                  |
       |                                                  help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:42:40
       |
    42 |         fn c_take_trivial_ns_ref(g: &G);
       |                                        ^
       |                                        |
       |                                        help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:43:35
       |
    43 |         fn c_take_trivial_ns(g: G);
       |                                   ^
       |                                   |
       |                                   help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:44:46
       |
    44 |         fn c_take_opaque_ptr(e: UniquePtr<E>);
       |                                              ^
       |                                              |
       |                                              help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:45:36
       |
    45 |         fn c_take_opaque_ref(e: &E);
       |                                    ^
       |                                    |
       |                                    help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:46:46
       |
    46 |         fn c_take_opaque_ref_method(self: &E);
       |                                              ^
       |                                              |
       |                                              help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:47:59
       |
    47 |         fn c_take_opaque_mut_ref_method(self: Pin<&mut E>);
       |                                                           ^
       |                                                           |
       |                                                           help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:48:49
       |
    48 |         fn c_take_opaque_ns_ptr(e: UniquePtr<F>);
       |                                                 ^
       |                                                 |
       |                                                 help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:49:39
       |
    49 |         fn c_take_opaque_ns_ref(e: &F);
       |                                       ^
       |                                       |
       |                                       help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:50:50
       |
    50 |         fn c_return_trivial_ptr() -> UniquePtr<D>;
       |                                                  ^
       |                                                  |
       |                                                  help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:51:35
       |
    51 |         fn c_return_trivial() -> D;
       |                                   ^
       |                                   |
       |                                   help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:52:53
       |
    52 |         fn c_return_trivial_ns_ptr() -> UniquePtr<G>;
       |                                                     ^
       |                                                     |
       |                                                     help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:53:38
       |
    53 |         fn c_return_trivial_ns() -> G;
       |                                      ^
       |                                      |
       |                                      help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:54:49
       |
    54 |         fn c_return_opaque_ptr() -> UniquePtr<E>;
       |                                                 ^
       |                                                 |
       |                                                 help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:55:66
       |
    55 |         fn c_return_opaque_mut_pin(e: Pin<&mut E>) -> Pin<&mut E>;
       |                                                                  ^
       |                                                                  |
       |                                                                  help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:56:52
       |
    56 |         fn c_return_ns_opaque_ptr() -> UniquePtr<F>;
       |                                                    ^
       |                                                    |
       |                                                    help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:57:52
       |
    57 |         fn c_return_ns_unique_ptr() -> UniquePtr<H>;
       |                                                    ^
       |                                                    |
       |                                                    help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:58:34
       |
    58 |         fn c_take_ref_ns_c(h: &H);
       |                                  ^
       |                                  |
       |                                  help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:61:35
       |
    61 |         fn ns_c_take_trivial(d: D);
       |                                   ^
       |                                   |
       |                                   help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:63:38
       |
    63 |         fn ns_c_return_trivial() -> D;
       |                                      ^
       |                                      |
       |                                      help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:68:32
       |
    68 |         fn get(self: &I) -> u32;
       |                                ^
       |                                |
       |                                help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:71:55
       |
    71 |         fn ns_c_return_unique_ptr_ns() -> UniquePtr<I>;
       |                                                       ^
       |                                                       |
       |                                                       help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:74:23
       |
    74 |     impl UniquePtr<D> {}
       |                       -^
       |                       |
       |                       help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:75:23
       |
    75 |     impl UniquePtr<E> {}
       |                       -^
       |                       |
       |                       help: needs `unsafe` before the extern keyword: `unsafe`
       |
       = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024!
       = note: for more information, see issue #123743 <https://github.com/rust-lang/rust/issues/123743>

    warning: extern blocks should be unsafe
      --> tests/ffi/module.rs:76:23
       |
    76 |     impl UniquePtr<F> {}
       |                       -^
       |                       |
       |                       help: needs `unsafe` before the extern keyword: `unsafe`
…
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-edition-2024 Area: The 2024 edition B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC F-unsafe_extern_blocks `#![feature(unsafe_extern_blocks)]` S-tracking-ready-for-edition Status: This issue is ready for inclusion in the edition. T-lang Relevant to the language team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

6 participants