This website requires JavaScript.
Explore
Help
Sign In
nordic-dev.net
/
rust
Watch
2
Star
0
Fork
0
You've already forked rust
mirror of
https://github.com/rust-lang/rust.git
synced
2025-05-01 20:47:36 +00:00
Code
Issues
Packages
Projects
Releases
Wiki
Activity
7b8644e5cf
rust
/
tests
/
ui
/
structs-enums
/
uninstantiable-struct.rs
5 lines
93 B
Rust
Raw
Normal View
History
Unescape
Escape
Add `// run-pass` annotations to all the tests under `ui/run-pass/`. (I may have accidentally added it to some auxilliary crates as well; my emacs-macro-based methodology was pretty crude.)
2018-08-30 12:18:55 +00:00
// run-pass
Warn about dead tuple struct fields
2022-07-25 20:36:03 +00:00
pub
struct
Z
(
#[
allow(unused_tuple_struct_fields)
]
&
'static
Z
)
;
register snapshots
2013-10-23 08:49:18 +00:00
Allow writing types which "can't" be instantiated. The borrow checker doesn't allow constructing such a type at runtime using safe code, but there isn't any reason to ban them in the type checker. Included in this commit is an example of a neat static doubly-linked list. Feature-gated under the static_recursion gate to be on the safe side, but there are unlikely to be any reasons this shouldn't be turned on by default.
2015-06-28 17:38:28 +00:00
pub
fn
main
(
)
{
}
Reference in New Issue
Copy Permalink