Implement fmt::Debug
for all structures in libstd.
Part of https://github.com/rust-lang/rust/issues/31869. Also turn on the `missing_debug_implementations` lint at the crate level.
This commit is contained in:
parent
1f965cc8e9
commit
86fc63e62d
31 changed files with 515 additions and 7 deletions
|
@ -12,6 +12,7 @@
|
|||
#![unstable(feature = "thread_local_internals", issue = "0")]
|
||||
|
||||
use cell::{Cell, UnsafeCell};
|
||||
use fmt;
|
||||
use intrinsics;
|
||||
use ptr;
|
||||
|
||||
|
@ -24,6 +25,12 @@ pub struct Key<T> {
|
|||
dtor_running: Cell<bool>,
|
||||
}
|
||||
|
||||
impl<T> fmt::Debug for Key<T> {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
f.pad("Key { .. }")
|
||||
}
|
||||
}
|
||||
|
||||
unsafe impl<T> ::marker::Sync for Key<T> { }
|
||||
|
||||
impl<T> Key<T> {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue