Parser icon indicating copy to clipboard operation
Parser copied to clipboard

Cannot compile with Rust 1.76.0

Open rubenfiszel opened this issue 1 year ago • 7 comments

Works with 1.75.0, but here is the issue with 1.76.0

  --> /home/rfiszel/.cargo/registry/src/index.crates.io-6f17d22bba15001f/rustpython-ast-0.3.0/src/impls.rs:60:1
   |
60 | static_assertions::assert_eq_size!(crate::Stmt, [u8; 160]);
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: source type: `generic::Stmt` (1216 bits)
   = note: target type: `[u8; 160]` (1280 bits)
   = note: this error originates in the macro `static_assertions::assert_eq_size` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0512]: cannot transmute between types of different sizes, or dependently-sized types
  --> /home/rfiszel/.cargo/registry/src/index.crates.io-6f17d22bba15001f/rustpython-ast-0.3.0/src/impls.rs:62:1
   |
62 | static_assertions::assert_eq_size!(crate::Pattern, [u8; 96]);
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: source type: `generic::Pattern` (704 bits)
   = note: target type: `[u8; 96]` (768 bits)
   = note: this error originates in the macro `static_assertions::assert_eq_size` (in Nightly builds, run with -Z macro-backtrace for more info)

rubenfiszel avatar Feb 08 '24 15:02 rubenfiszel

It seems it has been "fixed" in branch main by commenting out the problematic checks: cf 29c4728dbedc7e69cc2560b9b34058bbba9b1303 (at the time where Rust 1.76.0 was still "Nightly")

olivierlemasle avatar Feb 21 '24 19:02 olivierlemasle

Would be nice to have a new release that includes that fix.

jansol avatar Mar 23 '24 17:03 jansol

Is there an update on when to expect a new release?

bnkc avatar Apr 06 '24 01:04 bnkc

Sorry for inconvenience. I will release a new version.

youknowone avatar Apr 06 '24 16:04 youknowone

Did the new release fix everyone's problem?

fanninpm avatar Apr 08 '24 14:04 fanninpm

It did. Thankyou! @youknowone @fanninpm

bnkc avatar Apr 08 '24 16:04 bnkc

Great that this got fixed! You might want to update the README though.

Drvanon avatar Apr 14 '24 13:04 Drvanon