Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Suppress unused vars warning generated by gpui macro
Kirill Bulatov9f40a5c53f29
diff --git a/crates/gpui_macros/src/gpui_macros.rs b/crates/gpui_macros/src/gpui_macros.rsindex aa55c27eaad..62fba3b6123 100644--- a/crates/gpui_macros/src/gpui_macros.rs+++ b/crates/gpui_macros/src/gpui_macros.rs@@ -170,6 +170,8 @@ pub fn test(args: TokenStream, function: TokenStream) -> TokenStream {#max_retries,#detect_nondeterminism,&mut |cx, foreground_platform, deterministic, seed| {+ // some of the macro contents do not use all variables, silence the warnings+ let _ = (&cx, &foreground_platform, &deterministic, &seed);#cx_varscx.foreground().run(#inner_fn_name(#inner_fn_args));#cx_teardowns@@ -247,6 +249,8 @@ pub fn test(args: TokenStream, function: TokenStream) -> TokenStream {#max_retries,#detect_nondeterminism,&mut |cx, foreground_platform, deterministic, seed| {+ // some of the macro contents do not use all variables, silence the warnings+ let _ = (&cx, &foreground_platform, &deterministic, &seed);#cx_vars#inner_fn_name(#inner_fn_args);#cx_teardowns