Rollup merge of #72234 - dtolnay:default, r=petrochenkov
Implement Default for proc_macro::TokenStream Hopefully this is uncontroversial. The only reason we've made it this far without is that proc-macro2 snuck this in for their TokenStream.
This commit is contained in:
commit
25c91ea206
@ -158,6 +158,13 @@ impl fmt::Debug for TokenStream {
|
||||
}
|
||||
}
|
||||
|
||||
#[stable(feature = "proc_macro_token_stream_default", since = "1.45.0")]
|
||||
impl Default for TokenStream {
|
||||
fn default() -> Self {
|
||||
TokenStream::new()
|
||||
}
|
||||
}
|
||||
|
||||
#[unstable(feature = "proc_macro_quote", issue = "54722")]
|
||||
pub use quote::{quote, quote_span};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user