diff --git a/tests/compile-fail/static_is_sized.rs b/tests/compile-fail/static_is_sized.rs new file mode 100644 index 0000000..3719f97 --- /dev/null +++ b/tests/compile-fail/static_is_sized.rs @@ -0,0 +1,10 @@ +#[macro_use] +extern crate lazy_static; + +lazy_static! { + pub static ref FOO: str = panic!(); +} +//^ ERROR `str` does not have a constant size known at compile-time + +fn main() { +}