diff options
Diffstat (limited to 'patches/syn-2.patch')
-rw-r--r-- | patches/syn-2.patch | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/patches/syn-2.patch b/patches/syn-2.patch deleted file mode 100644 index 7a8225c..0000000 --- a/patches/syn-2.patch +++ /dev/null @@ -1,36 +0,0 @@ -diff --git a/src/lib.rs b/src/lib.rs -index 7309648..03fb529 100644 ---- a/src/lib.rs -+++ b/src/lib.rs -@@ -1,4 +1,3 @@ --extern crate proc_macro; - use proc_macro::TokenStream; - use proc_macro2::{Group, TokenStream as TokenStream2, TokenTree}; - use quote::quote; -@@ -148,7 +147,7 @@ impl VisitMut for Scrub<'_> { - syn::Expr::ForLoop(expr) => { - syn::visit_mut::visit_expr_for_loop_mut(self, expr); - // TODO: Should we allow other attributes? -- if expr.attrs.len() != 1 || !expr.attrs[0].path.is_ident("await") { -+ if expr.attrs.len() != 1 || !expr.attrs[0].path().is_ident("await_") { - return; - } - let syn::ExprForLoop { -@@ -161,7 +160,7 @@ impl VisitMut for Scrub<'_> { - } = expr; - - let attr = attrs.pop().unwrap(); -- if let Err(e) = syn::parse2::<syn::parse::Nothing>(attr.tokens) { -+ if let Err(e) = attr.meta.require_path_only() { - *i = syn::parse2(e.to_compile_error()).unwrap(); - return; - } -@@ -281,7 +280,7 @@ fn replace_for_await(input: impl IntoIterator<Item = TokenTree>) -> TokenStream2 - TokenTree::Ident(ident) => { - match input.peek() { - Some(TokenTree::Ident(next)) if ident == "for" && next == "await" => { -- tokens.extend(quote!(#[#next])); -+ tokens.extend(quote!(#[await_])); - let _ = input.next(); - } - _ => {} |