commit | 998f642a73284a89c3de553e977a0683cb06bf66 | [log] [tgz] |
---|---|---|
author | Alex Crichton <alex@alexcrichton.com> | Sun Nov 19 08:06:27 2017 -0800 |
committer | Alex Crichton <alex@alexcrichton.com> | Sun Nov 19 08:06:27 2017 -0800 |
tree | 92f04dc070801adf0079c5a94b9bf69f62706c56 | |
parent | a5aa9b9467f8e498bf425db53d110989dd49c5f6 [diff] [blame] |
Update to latest nightly's API
diff --git a/src/unstable.rs b/src/unstable.rs index 916ac46..a3ce1fd 100644 --- a/src/unstable.rs +++ b/src/unstable.rs
@@ -159,7 +159,7 @@ } } -#[derive(Copy, Clone, Default)] +#[derive(Copy, Clone)] pub struct Span(proc_macro::Span); impl Span { @@ -168,6 +168,12 @@ } } +impl Default for Span { + fn default() -> Span { + Span(proc_macro::Span::def_site()) + } +} + impl fmt::Debug for Span { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { self.0.fmt(f)