diff options
Diffstat (limited to 'lazy-static/compiletest/tests/compile-fail/static_is_sized.rs')
-rw-r--r-- | lazy-static/compiletest/tests/compile-fail/static_is_sized.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lazy-static/compiletest/tests/compile-fail/static_is_sized.rs b/lazy-static/compiletest/tests/compile-fail/static_is_sized.rs new file mode 100644 index 0000000..ac1cad4 --- /dev/null +++ b/lazy-static/compiletest/tests/compile-fail/static_is_sized.rs @@ -0,0 +1,11 @@ +// error-pattern:the size for values of type `str` cannot be known at compilation time +#[macro_use] +extern crate lazy_static_compiletest as lazy_static; + +lazy_static! { + pub static ref FOO: str = panic!(); +} + + +fn main() { +} |