Skip to content
This repository was archived by the owner on May 23, 2024. It is now read-only.

ices/82836.rs: fixed with no errors#1661

Merged
JohnTitor merged 1 commit intomasterfrom
autofix/ices/82836.rs
Sep 21, 2023
Merged

ices/82836.rs: fixed with no errors#1661
JohnTitor merged 1 commit intomasterfrom
autofix/ices/82836.rs

Conversation

@github-actions
Copy link
Contributor

Issue: rust-lang/rust#82836

extern "C" fn _panic<'a, T: ?Sized>() -> Option<&'a T> {
    panic!()
}

fn main() {}
=== stdout ===
=== stderr ===
warning: `extern` fn uses type `Option<&T>`, which is not FFI-safe
 --> /home/runner/work/glacier/glacier/ices/82836.rs:1:42
  |
1 | extern "C" fn _panic<'a, T: ?Sized>() -> Option<&'a T> {
  |                                          ^^^^^^^^^^^^^ not FFI-safe
  |
  = help: consider adding a `#[repr(C)]`, `#[repr(transparent)]`, or integer `#[repr(...)]` attribute to this enum
  = note: enum has no representation hint
  = note: `#[warn(improper_ctypes_definitions)]` on by default

warning: 1 warning emitted

==============

=== stdout ===
=== stderr ===
warning: `extern` fn uses type `Option<&T>`, which is not FFI-safe
 --> /home/runner/work/glacier/glacier/ices/82836.rs:1:42
  |
1 | extern "C" fn _panic<'a, T: ?Sized>() -> Option<&'a T> {
  |                                          ^^^^^^^^^^^^^ not FFI-safe
  |
  = help: consider adding a `#[repr(C)]`, `#[repr(transparent)]`, or integer `#[repr(...)]` attribute to this enum
  = note: enum has no representation hint
  = note: `#[warn(improper_ctypes_definitions)]` on by default

warning: 1 warning emitted

==============
@JohnTitor JohnTitor merged commit f469d68 into master Sep 21, 2023
@JohnTitor JohnTitor deleted the autofix/ices/82836.rs branch September 21, 2023 18:32
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants