diff options
Diffstat (limited to 'src/libsyntax/attr.rs')
| -rw-r--r-- | src/libsyntax/attr.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/libsyntax/attr.rs b/src/libsyntax/attr.rs index c5cffc401a1..416fc8c2278 100644 --- a/src/libsyntax/attr.rs +++ b/src/libsyntax/attr.rs @@ -28,6 +28,7 @@ use ptr::P; use std::cell::{RefCell, Cell}; use std::collections::BitvSet; use std::collections::HashSet; +use std::fmt; thread_local! { static USED_ATTRS: RefCell<BitvSet> = RefCell::new(BitvSet::new()) } @@ -357,6 +358,12 @@ pub enum StabilityLevel { Locked } +impl fmt::String for StabilityLevel { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + fmt::Show::fmt(self, f) + } +} + pub fn find_stability_generic<'a, AM: AttrMetaMethods, I: Iterator<Item=&'a AM>> |
