Skip to content
This repository was archived by the owner on Aug 25, 2025. It is now read-only.

Conversation

sharksforarms
Copy link

Cleanup of some warnings in example

$ cargo +nightly build --release --target wasm32-unknown-unknown

   Compiling wee_alloc_example v0.1.0 (/home/sharks/source/wee_alloc/example)
warning: unnecessary `unsafe` block
  --> example/src/lib.rs:24:5
   |
24 |     unsafe {
   |     ^^^^^^ unnecessary `unsafe` block
   |
   = note: `#[warn(unused_unsafe)]` on by default

warning: unnecessary `unsafe` block
  --> example/src/lib.rs:34:5
   |
34 |     unsafe {
   |     ^^^^^^ unnecessary `unsafe` block

warning: `extern` fn uses type `core::alloc::Layout`, which is not FFI-safe
  --> example/src/lib.rs:33:26
   |
33 | pub extern "C" fn oom(_: ::core::alloc::Layout) -> ! {
   |                          ^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
   |
   = note: `#[warn(improper_ctypes_definitions)]` on by default
   = help: consider adding a `#[repr(C)]` or `#[repr(transparent)]` attribute to this struct
   = note: this struct has unspecified layout

warning: 3 warnings emitted

    Finished release [optimized + debuginfo] target(s) in 0.21s

@sharksforarms
Copy link
Author

CI failing for another reason possibly

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.

1 participant