@@ -265,13 +265,13 @@ fn add_query_description_impl(query: &Query, impls: &mut proc_macro2::TokenStrea
265265 let try_load_from_disk = if let Some ( ( tcx, id, block) ) = modifiers. load_cached . as_ref ( ) {
266266 // Use custom code to load the query from disk
267267 quote ! {
268- const TRY_LOAD_FROM_DISK : Option <fn ( QueryCtxt <$ tcx>, SerializedDepNodeIndex ) -> Option <Self :: Value >>
268+ const TRY_LOAD_FROM_DISK : Option <fn ( QueryCtxt <' tcx>, SerializedDepNodeIndex ) -> Option <Self :: Value >>
269269 = Some ( |#tcx, #id| { #block } ) ;
270270 }
271271 } else {
272272 // Use the default code to load the query from disk
273273 quote ! {
274- const TRY_LOAD_FROM_DISK : Option <fn ( QueryCtxt <$ tcx>, SerializedDepNodeIndex ) -> Option <Self :: Value >>
274+ const TRY_LOAD_FROM_DISK : Option <fn ( QueryCtxt <' tcx>, SerializedDepNodeIndex ) -> Option <Self :: Value >>
275275 = Some ( |tcx, id| tcx. on_disk_cache( ) . as_ref( ) ?. try_load_query_result( * tcx, id) ) ;
276276 }
277277 } ;
@@ -298,7 +298,7 @@ fn add_query_description_impl(query: &Query, impls: &mut proc_macro2::TokenStrea
298298 false
299299 }
300300
301- const TRY_LOAD_FROM_DISK : Option <fn ( QueryCtxt <$ tcx>, SerializedDepNodeIndex ) -> Option <Self :: Value >> = None ;
301+ const TRY_LOAD_FROM_DISK : Option <fn ( QueryCtxt <' tcx>, SerializedDepNodeIndex ) -> Option <Self :: Value >> = None ;
302302 }
303303 } ;
304304
@@ -307,7 +307,7 @@ fn add_query_description_impl(query: &Query, impls: &mut proc_macro2::TokenStrea
307307
308308 let desc = quote ! {
309309 #[ allow( unused_variables) ]
310- fn describe( tcx: QueryCtxt <$ tcx>, key: Self :: Key ) -> String {
310+ fn describe( tcx: QueryCtxt <' tcx>, key: Self :: Key ) -> String {
311311 let ( #tcx, #key) = ( * tcx, key) ;
312312 :: rustc_middle:: ty:: print:: with_no_trimmed_paths!(
313313 format!( #desc)
@@ -316,7 +316,7 @@ fn add_query_description_impl(query: &Query, impls: &mut proc_macro2::TokenStrea
316316 } ;
317317
318318 impls. extend ( quote ! {
319- ( #name<$tcx : tt> ) => {
319+ ( #name) => {
320320 #desc
321321 #cache
322322 } ;
@@ -411,15 +411,15 @@ pub fn rustc_queries(input: TokenStream) -> TokenStream {
411411 TokenStream :: from ( quote ! {
412412 #[ macro_export]
413413 macro_rules! rustc_query_append {
414- ( [ $ ( $ macro: tt ) * ] ) => {
415- $( $ macro) * {
414+ ( $ macro: ident ! ) => {
415+ $macro! {
416416 #query_stream
417417 }
418418 }
419419 }
420420 macro_rules! rustc_dep_node_append {
421- ( [ $ ( $ macro: tt ) * ] [ $( $other: tt) * ] ) => {
422- $( $ macro) * (
421+ ( $ macro: ident! [ $( $other: tt) * ] ) => {
422+ $macro! (
423423 $( $other) *
424424
425425 #dep_node_def_stream
@@ -428,8 +428,8 @@ pub fn rustc_queries(input: TokenStream) -> TokenStream {
428428 }
429429 #[ macro_export]
430430 macro_rules! rustc_cached_queries {
431- ( $ ( $ macro: tt ) * ) => {
432- $( $ macro) * ( #cached_queries) ;
431+ ( $ macro: ident! ) => {
432+ $macro! ( #cached_queries) ;
433433 }
434434 }
435435 #[ macro_export]
0 commit comments