0.3.0 breaks Rust 2018 style macro imports
yvt opened this issue · 6 comments
yvt commented
The following code no longer compiles as of 0.3.0:
use static_assertions::const_assert;
fn main() {
const_assert!(true);
}
error: cannot find macro `_const_assert!` in this scope
--> src/main.rs:4:5
|
4 | const_assert!(true);
| ^^^^^^^^^^^^^^^^^^^^ help: you could try the macro: `const_assert`
|
= note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info)
Related: rust-lang-nursery/lazy-static.rs#107
gin-ahirsch commented
Commit d5994b6 broke this again.
nvzqz commented
@gin-ahirsch OP's example works for me with 1.0. What error are you getting?
gin-ahirsch commented
Ah indeed, const_assert!
does work. assert_qe_size_val!
does not though: error: cannot find macro `assert_eq_size_ptr!` in this scope
.