Skip to content

bug: size-of dependency failed to compile on rust nightly-06-18 #135

@fiamma-builder

Description

@fiamma-builder

Bug Report

**types-rs version: 0.1.7 **

My project depends on starknet-rs, and a warning appeared during compilation. warning: the following packages contain code that will be rejected by a future version of Rust: size-of v0.1.5
note: to see what the problems were, use the option --future-incompat-report, or run cargo report future-incompatibilities --id 1

Then I checked the project's dependency tree, which shows that this size-of is imported by starknet-rs via https://github.com/starknet-io/types-rs , my toolchain version :

 [toolchain]
channel = "nightly-2025-06-05"

Of course, if it were just a warning, it wouldn't be a big deal and would be acceptable. However, when I tried to change the Rust version to nightly-06-18 to compile my project, it directly threw an error with the error message.

  --> /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/macros.rs:66:56
    |
66  |               impl<$($ty,)* U> $crate::SizeOf for extern $cconv fn($($ty),*) -> U {
    |                                                          ^^^^^^
    |
   ::: /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/core_impls.rs:294:1
    |
294 | / impl_function_ptrs! {
295 | |     "C",
296 | |     "Rust",
297 | |     "aapcs",
...   |
303 | |     "fastcall",
304 | | }
    | |_- in this macro invocation
    |
    = note: this error originates in the macro `impl_function_ptrs` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0570]: "win64" is not a supported ABI for the current target
   --> /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/macros.rs:66:56
    |
66  |               impl<$($ty,)* U> $crate::SizeOf for extern $cconv fn($($ty),*) -> U {
    |                                                          ^^^^^^
    |
   ::: /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/core_impls.rs:294:1
    |
294 | / impl_function_ptrs! {
295 | |     "C",
296 | |     "Rust",
297 | |     "aapcs",
...   |
303 | |     "fastcall",
304 | | }
    | |_- in this macro invocation
    |
    = note: this error originates in the macro `impl_function_ptrs` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0570]: "sysv64" is not a supported ABI for the current target
   --> /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/macros.rs:66:56
    |
66  |               impl<$($ty,)* U> $crate::SizeOf for extern $cconv fn($($ty),*) -> U {
    |                                                          ^^^^^^
    |
   ::: /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/core_impls.rs:294:1
    |
294 | / impl_function_ptrs! {
295 | |     "C",
296 | |     "Rust",
297 | |     "aapcs",
...   |
303 | |     "fastcall",
304 | | }
    | |_- in this macro invocation
    |
    = note: this error originates in the macro `impl_function_ptrs` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0570]: "stdcall" is not a supported ABI for the current target
   --> /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/macros.rs:66:56
    |
66  |               impl<$($ty,)* U> $crate::SizeOf for extern $cconv fn($($ty),*) -> U {
    |                                                          ^^^^^^
    |
   ::: /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/core_impls.rs:294:1
    |
294 | / impl_function_ptrs! {
295 | |     "C",
296 | |     "Rust",
297 | |     "aapcs",
...   |
303 | |     "fastcall",
304 | | }
    | |_- in this macro invocation
    |
    = help: if you need `extern "stdcall"` on win32 and `extern "C"` everywhere else, use `extern "system"`
    = note: this error originates in the macro `impl_function_ptrs` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0570]: "fastcall" is not a supported ABI for the current target
   --> /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/macros.rs:66:56
    |
66  |               impl<$($ty,)* U> $crate::SizeOf for extern $cconv fn($($ty),*) -> U {
    |                                                          ^^^^^^
    |
   ::: /Users/panos/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/size-of-0.1.5/src/core_impls.rs:294:1
    |
294 | / impl_function_ptrs! {
295 | |     "C",
296 | |     "Rust",
297 | |     "aapcs",
...   |
303 | |     "fastcall",
304 | | }
    | |_- in this macro invocation
    |
    = note: this error originates in the macro `impl_function_ptrs` (in Nightly builds, run with -Z macro-backtrace for more info)

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions