Repository: rust-lang/rust-analyzer
Pull request #18880 (2025-01-08 02:58:34)

Add config setting which allows adding additional include paths to the VFS.
The motivation for this is resolving unresolved symbols for Firefox. We build Rust code with cargo but generate some code via our primary build system mach. Additionally, we bundle the windows crate in an out-of-source and out-of-build location. Essentially the same idea as discussed [here](https://rust-lang.zulipchat.com/#narrow/channel/185405-t-compiler.2Frust-analyzer/topic/include!.20failing.20for.20some.20paths), Firefox issue tracked [here](https://bugzilla.mozilla.org/show_bug.cgi?id=1890431).

I investigated instead populating the vfs via rustc's `--emit=dep-info` as cargo already emits .d files but at this time cargo [does not relay .d file changes](https://github.com/rust-lang/cargo/issues/13672#issuecomment-2147772916) as it hazards the unspecified cargo directory layout becoming defacto specified.

This change therefore instead adds a config option to manually specify extra includes for the VFS as suggested in the above Zulip conversation and in this [bug](https://github.com/rust-lang/rust-analyzer/issues/17040#issuecomment-2105778865) (similarly motivated by Firefox's needs).

I don't believe this change ready to land but it's in a place where it's sufficient to anchor a conversation on what's necessary beyond a minimal implementation, and I've verified this works with both Firefox's XPCOM generated functions and windows includes.

Veykril: You'll need to run the tests in the rust-analyzer crate (that will regenerate some files) `cargo test -p rust-analyzer` as well as move the config so its in lexicographic order (that one should be done first as it affects the generated file).

Patch:
diff --git a/Cargo.toml b/Cargo.toml
index 629bd74467..9440123de7 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -79,7 +79,6 @@ span = { path = "./crates/span", version = "0.0.0" }
 stdx = { path = "./crates/stdx", version = "0.0.0" }
 syntax = { path = "./crates/syntax", version = "0.0.0" }
 syntax-bridge = { path = "./crates/syntax-bridge", version = "0.0.0" }
-test-fixture = { path = "./crates/test-fixture", version = "0.0.0" }
 test-utils = { path = "./crates/test-utils", version = "0.0.0" }
 toolchain = { path = "./crates/toolchain", version = "0.0.0" }
 tt = { path = "./crates/tt", version = "0.0.0" }
@@ -94,8 +93,9 @@ ra-ap-rustc_abi = { version = "0.87", default-features = false }
 ra-ap-rustc_pattern_analysis = { version = "0.87", default-features = false }
 
 # local crates that aren't published to crates.io. These should not have versions.
+test-fixture = { path = "./crates/test-fixture" }
 
-# in-tree crates that are published separately and follow semver. See lib/README.md
+# In-tree crates that are published separately and follow semver. See lib/README.md
 line-index = { version = "0.1.2" }
 la-arena = { version = "0.3.1" }
 lsp-server = { version = "0.7.6" }
diff --git a/crates/hir/src/lib.rs b/crates/hir/src/lib.rs
index b7c3e6bb41..00b4db5437 100644
--- a/crates/hir/src/lib.rs
+++ b/crates/hir/src/lib.rs
@@ -3046,23 +3046,14 @@ impl Macro {
             MacroId::Macro2Id(it) => {
                 matches!(it.lookup(db.upcast()).expander, MacroExpander::BuiltInEager(eager) if eager.is_env_or_option_env())
             }
-            MacroId::MacroRulesId(it) => {
-                matches!(it.lookup(db.upcast()).expander, MacroExpander::BuiltInEager(eager) if eager.is_env_or_option_env())
-            }
-            MacroId::ProcMacroId(_) => false,
+            MacroId::MacroRulesId(_) | MacroId::ProcMacroId(_) => false,
         }
     }
 
     pub fn is_asm_or_global_asm(&self, db: &dyn HirDatabase) -> bool {
-        match self.id {
-            MacroId::Macro2Id(it) => {
-                matches!(it.lookup(db.upcast()).expander, MacroExpander::BuiltIn(m) if m.is_asm())
-            }
-            MacroId::MacroRulesId(it) => {
-                matches!(it.lookup(db.upcast()).expander, MacroExpander::BuiltIn(m) if m.is_asm())
-            }
-            MacroId::ProcMacroId(_) => false,
-        }
+        matches!(self.id, MacroId::Macro2Id(it) if {
+            matches!(it.lookup(db.upcast()).expander, MacroExpander::BuiltIn(m) if m.is_asm())
+        })
     }
 
     pub fn is_attr(&self, db: &dyn HirDatabase) -> bool {
diff --git a/crates/ide-assists/src/handlers/add_missing_match_arms.rs b/crates/ide-assists/src/handlers/add_missing_match_arms.rs
index 5899ec5a00..24b34f140b 100644
--- a/crates/ide-assists/src/handlers/add_missing_match_arms.rs
+++ b/crates/ide-assists/src/handlers/add_missing_match_arms.rs
@@ -212,7 +212,8 @@ pub(crate) fn add_missing_match_arms(acc: &mut Assists, ctx: &AssistContext<'_>)
                     !hidden
                 })
                 .map(|(pat, _)| {
-                    make::match_arm(pat, None, make::ext::expr_todo()).clone_for_update()
+                    make::match_arm(iter::once(pat), None, make::ext::expr_todo())
+                        .clone_for_update()
                 });
 
             let catch_all_arm = new_match_arm_list
@@ -242,9 +243,12 @@ pub(crate) fn add_missing_match_arms(acc: &mut Assists, ctx: &AssistContext<'_>)
 
             if needs_catch_all_arm && !has_catch_all_arm {
                 cov_mark::hit!(added_wildcard_pattern);
-                let arm =
-                    make::match_arm(make::wildcard_pat().into(), None, make::ext::expr_todo())
-                        .clone_for_update();
+                let arm = make::match_arm(
+                    iter::once(make::wildcard_pat().into()),
+                    None,
+                    make::ext::expr_todo(),
+                )
+                .clone_for_update();
                 todo_placeholders.push(arm.expr().unwrap());
                 added_arms.push(arm);
             }
diff --git a/crates/ide-assists/src/handlers/apply_demorgan.rs b/crates/ide-assists/src/handlers/apply_demorgan.rs
index 70fb568005..f178a7e0ce 100644
--- a/crates/ide-assists/src/handlers/apply_demorgan.rs
+++ b/crates/ide-assists/src/handlers/apply_demorgan.rs
@@ -252,7 +252,7 @@ fn tail_cb_impl(edit: &mut SourceChangeBuilder, e: &ast::Expr) {
 
 /// Add bang and parentheses to the expression.
 fn add_bang_paren(expr: ast::Expr) -> ast::Expr {
-    make::expr_prefix(T![!], make::expr_paren(expr)).into()
+    make::expr_prefix(T![!], make::expr_paren(expr))
 }
 
 #[cfg(test)]
diff --git a/crates/ide-assists/src/handlers/bool_to_enum.rs b/crates/ide-assists/src/handlers/bool_to_enum.rs
index cbd3979624..f699899066 100644
--- a/crates/ide-assists/src/handlers/bool_to_enum.rs
+++ b/crates/ide-assists/src/handlers/bool_to_enum.rs
@@ -195,7 +195,6 @@ fn bool_expr_to_enum_expr(expr: ast::Expr) -> ast::Expr {
             make::tail_only_block_expr(true_expr),
             Some(ast::ElseBranch::Block(make::tail_only_block_expr(false_expr))),
         )
-        .into()
     }
 }
 
diff --git a/crates/ide-assists/src/handlers/convert_closure_to_fn.rs b/crates/ide-assists/src/handlers/convert_closure_to_fn.rs
index bb04a43cf9..79f303b37a 100644
--- a/crates/ide-assists/src/handlers/convert_closure_to_fn.rs
+++ b/crates/ide-assists/src/handlers/convert_closure_to_fn.rs
@@ -507,7 +507,7 @@ fn wrap_capture_in_deref_if_needed(
     if does_autoderef {
         return capture_name;
     }
-    make::expr_prefix(T![*], capture_name).into()
+    make::expr_prefix(T![*], capture_name)
 }
 
 fn capture_as_arg(ctx: &AssistContext<'_>, capture: &ClosureCapture) -> ast::Expr {
diff --git a/crates/ide-assists/src/handlers/convert_from_to_tryfrom.rs b/crates/ide-assists/src/handlers/convert_from_to_tryfrom.rs
index dd2e9cbcb5..67c72a93da 100644
--- a/crates/ide-assists/src/handlers/convert_from_to_tryfrom.rs
+++ b/crates/ide-assists/src/handlers/convert_from_to_tryfrom.rs
@@ -97,7 +97,7 @@ pub(crate) fn convert_from_to_tryfrom(acc: &mut Assists, ctx: &AssistContext<'_>
             );
 
             for r in return_exprs {
-                let t = r.expr().unwrap_or_else(make::ext::expr_unit);
+                let t = r.expr().unwrap_or_else(make::expr_unit);
                 ted::replace(t.syntax(), wrap_ok(t.clone()).syntax().clone_for_update());
             }
 
diff --git a/crates/ide-assists/src/handlers/convert_while_to_loop.rs b/crates/ide-assists/src/handlers/convert_while_to_loop.rs
index 0b92beefbc..434daa279c 100644
--- a/crates/ide-assists/src/handlers/convert_while_to_loop.rs
+++ b/crates/ide-assists/src/handlers/convert_while_to_loop.rs
@@ -60,7 +60,7 @@ pub(crate) fn convert_while_to_loop(acc: &mut Assists, ctx: &AssistContext<'_>)
             .indent(while_indent_level);
             let block_expr = if is_pattern_cond(while_cond.clone()) {
                 let if_expr = make::expr_if(while_cond, while_body, Some(break_block.into()));
-                let stmts = iter::once(make::expr_stmt(if_expr.into()).into());
+                let stmts = iter::once(make::expr_stmt(if_expr).into());
                 make::block_expr(stmts, None)
             } else {
                 let if_cond = invert_boolean_expression(while_cond);
diff --git a/crates/ide-assists/src/handlers/extract_function.rs b/crates/ide-assists/src/handlers/extract_function.rs
index 967da41c15..0d1b6af720 100644
--- a/crates/ide-assists/src/handlers/extract_function.rs
+++ b/crates/ide-assists/src/handlers/extract_function.rs
@@ -1533,7 +1533,7 @@ impl FlowHandler {
                     .into(),
                     call_expr,
                 );
-                make::expr_if(condition.into(), block, None).into()
+                make::expr_if(condition.into(), block, None)
             }
             FlowHandler::IfOption { action } => {
                 let path = make::ext::ident_path("Some");
@@ -1544,7 +1544,7 @@ impl FlowHandler {
                 let action_expr = action.make_result_handler(Some(value));
                 let action_stmt = make::expr_stmt(action_expr);
                 let then = make::block_expr(iter::once(action_stmt.into()), None);
-                make::expr_if(cond.into(), then, None).into()
+                make::expr_if(cond.into(), then, None)
             }
             FlowHandler::MatchOption { none } => {
                 let some_name = "value";
@@ -1554,15 +1554,15 @@ impl FlowHandler {
                     let value_pat = make::ext::simple_ident_pat(make::name(some_name));
                     let pat = make::tuple_struct_pat(path, iter::once(value_pat.into()));
                     let value = make::expr_path(make::ext::ident_path(some_name));
-                    make::match_arm(pat.into(), None, value)
+                    make::match_arm(iter::once(pat.into()), None, value)
                 };
                 let none_arm = {
                     let path = make::ext::ident_path("None");
                     let pat = make::path_pat(path);
-                    make::match_arm(pat, None, none.make_result_handler(None))
+                    make::match_arm(iter::once(pat), None, none.make_result_handler(None))
                 };
                 let arms = make::match_arm_list(vec![some_arm, none_arm]);
-                make::expr_match(call_expr, arms).into()
+                make::expr_match(call_expr, arms)
             }
             FlowHandler::MatchResult { err } => {
                 let ok_name = "value";
@@ -1573,17 +1573,21 @@ impl FlowHandler {
                     let value_pat = make::ext::simple_ident_pat(make::name(ok_name));
                     let pat = make::tuple_struct_pat(path, iter::once(value_pat.into()));
                     let value = make::expr_path(make::ext::ident_path(ok_name));
-                    make::match_arm(pat.into(), None, value)
+                    make::match_arm(iter::once(pat.into()), None, value)
                 };
                 let err_arm = {
                     let path = make::ext::ident_path("Err");
                     let value_pat = make::ext::simple_ident_pat(make::name(err_name));
                     let pat = make::tuple_struct_pat(path, iter::once(value_pat.into()));
                     let value = make::expr_path(make::ext::ident_path(err_name));
-                    make::match_arm(pat.into(), None, err.make_result_handler(Some(value)))
+                    make::match_arm(
+                        iter::once(pat.into()),
+                        None,
+                        err.make_result_handler(Some(value)),
+                    )
                 };
                 let arms = make::match_arm_list(vec![ok_arm, err_arm]);
-                make::expr_match(call_expr, arms).into()
+                make::expr_match(call_expr, arms)
             }
         }
     }
@@ -1875,7 +1879,7 @@ fn make_body(ctx: &AssistContext<'_>, old_indent: IndentLevel, fun: &Function) -
                             .iter()
                             .map(|var| path_expr_from_local(ctx, var.local, fun.mods.edition));
                         let expr = make::expr_tuple(exprs);
-                        tail_expr = Some(expr.into());
+                        tail_expr = Some(expr);
                     }
                 },
             };
@@ -1906,7 +1910,7 @@ fn make_body(ctx: &AssistContext<'_>, old_indent: IndentLevel, fun: &Function) -
     match &handler {
         FlowHandler::None => block,
         FlowHandler::Try { kind } => {
-            let block = with_default_tail_expr(block, make::ext::expr_unit());
+            let block = with_default_tail_expr(block, make::expr_unit());
             map_tail_expr(block, |tail_expr| {
                 let constructor = match kind {
                     TryKind::Option => "Some",
@@ -1920,7 +1924,7 @@ fn make_body(ctx: &AssistContext<'_>, old_indent: IndentLevel, fun: &Function) -
         FlowHandler::If { .. } => {
             let controlflow_continue = make::expr_call(
                 make::expr_path(make::path_from_text("ControlFlow::Continue")),
-                make::arg_list([make::ext::expr_unit()]),
+                make::arg_list(iter::once(make::expr_unit())),
             );
             with_tail_expr(block, controlflow_continue)
         }
@@ -2123,17 +2127,17 @@ fn make_rewritten_flow(handler: &FlowHandler, arg_expr: Option<ast::Expr>) -> Op
         FlowHandler::None | FlowHandler::Try { .. } => return None,
         FlowHandler::If { .. } => make::expr_call(
             make::expr_path(make::path_from_text("ControlFlow::Break")),
-            make::arg_list([make::ext::expr_unit()]),
+            make::arg_list(iter::once(make::expr_unit())),
         ),
         FlowHandler::IfOption { .. } => {
-            let expr = arg_expr.unwrap_or_else(make::ext::expr_unit);
-            let args = make::arg_list([expr]);
+            let expr = arg_expr.unwrap_or_else(|| make::expr_tuple(Vec::new()));
+            let args = make::arg_list(iter::once(expr));
             make::expr_call(make::expr_path(make::ext::ident_path("Some")), args)
         }
         FlowHandler::MatchOption { .. } => make::expr_path(make::ext::ident_path("None")),
         FlowHandler::MatchResult { .. } => {
-            let expr = arg_expr.unwrap_or_else(make::ext::expr_unit);
-            let args = make::arg_list([expr]);
+            let expr = arg_expr.unwrap_or_else(|| make::expr_tuple(Vec::new()));
+            let args = make::arg_list(iter::once(expr));
             make::expr_call(make::expr_path(make::ext::ident_path("Err")), args)
         }
     };
diff --git a/crates/ide-assists/src/handlers/move_guard.rs b/crates/ide-assists/src/handlers/move_guard.rs
index a487960d8d..f0c96fe3cb 100644
--- a/crates/ide-assists/src/handlers/move_guard.rs
+++ b/crates/ide-assists/src/handlers/move_guard.rs
@@ -61,7 +61,7 @@ pub(crate) fn move_guard_to_arm_body(acc: &mut Assists, ctx: &AssistContext<'_>)
             };
 
             edit.delete(guard.syntax().text_range());
-            edit.replace_ast(arm_expr, if_expr.into());
+            edit.replace_ast(arm_expr, if_expr);
         },
     )
 }
diff --git a/crates/ide-assists/src/handlers/remove_dbg.rs b/crates/ide-assists/src/handlers/remove_dbg.rs
index ae14075c26..94274f6d17 100644
--- a/crates/ide-assists/src/handlers/remove_dbg.rs
+++ b/crates/ide-assists/src/handlers/remove_dbg.rs
@@ -102,7 +102,7 @@ fn compute_dbg_replacement(macro_expr: ast::MacroExpr) -> Option<(TextRange, Opt
                         };
                         (range, None)
                     },
-                    _ => (macro_call.syntax().text_range(), Some(make::ext::expr_unit())),
+                    _ => (macro_call.syntax().text_range(), Some(make::expr_unit())),
                 }
             }
         }
@@ -152,7 +152,7 @@ fn compute_dbg_replacement(macro_expr: ast::MacroExpr) -> Option<(TextRange, Opt
         exprs => {
             let exprs = exprs.iter().cloned().map(replace_nested_dbgs);
             let expr = make::expr_tuple(exprs);
-            (macro_call.syntax().text_range(), Some(expr.into()))
+            (macro_call.syntax().text_range(), Some(expr))
         }
     })
 }
diff --git a/crates/ide-assists/src/handlers/replace_if_let_with_match.rs b/crates/ide-assists/src/handlers/replace_if_let_with_match.rs
index e324d6eaaa..b31d45e6d4 100644
--- a/crates/ide-assists/src/handlers/replace_if_let_with_match.rs
+++ b/crates/ide-assists/src/handlers/replace_if_let_with_match.rs
@@ -1,4 +1,4 @@
-use std::iter::successors;
+use std::iter::{self, successors};
 
 use either::Either;
 use ide_db::{
@@ -8,7 +8,11 @@ use ide_db::{
     RootDatabase,
 };
 use syntax::{
-    ast::{self, edit::IndentLevel, edit_in_place::Indent, syntax_factory::SyntaxFactory, HasName},
+    ast::{
+        self,
+        edit::{AstNodeEdit, IndentLevel},
+        make, HasName,
+    },
     AstNode, TextRange, T,
 };
 
@@ -104,58 +108,53 @@ pub(crate) fn replace_if_let_with_match(acc: &mut Assists, ctx: &AssistContext<'
         AssistId("replace_if_let_with_match", AssistKind::RefactorRewrite),
         format!("Replace if{let_} with match"),
         available_range,
-        move |builder| {
-            let make = SyntaxFactory::new();
+        move |edit| {
             let match_expr = {
-                let else_arm = make_else_arm(ctx, &make, else_block, &cond_bodies);
+                let else_arm = make_else_arm(ctx, else_block, &cond_bodies);
                 let make_match_arm = |(pat, body): (_, ast::BlockExpr)| {
-                    let body = make.block_expr(body.statements(), body.tail_expr());
-                    body.indent(IndentLevel::from(1));
-                    let body = unwrap_trivial_block(body);
+                    let body = body.reset_indent().indent(IndentLevel(1));
                     match pat {
-                        Either::Left(pat) => make.match_arm(pat, None, body),
-                        Either::Right(_) if !pat_seen => {
-                            make.match_arm(make.literal_pat("true").into(), None, body)
+                        Either::Left(pat) => {
+                            make::match_arm(iter::once(pat), None, unwrap_trivial_block(body))
                         }
-                        Either::Right(expr) => make.match_arm(
-                            make.wildcard_pat().into(),
-                            Some(make.match_guard(expr)),
-                            body,
+                        Either::Right(_) if !pat_seen => make::match_arm(
+                            iter::once(make::literal_pat("true").into()),
+                            None,
+                            unwrap_trivial_block(body),
+                        ),
+                        Either::Right(expr) => make::match_arm(
+                            iter::once(make::wildcard_pat().into()),
+                            Some(expr),
+                            unwrap_trivial_block(body),
                         ),
                     }
                 };
-                let arms = cond_bodies.into_iter().map(make_match_arm).chain([else_arm]);
-                let match_expr = make.expr_match(scrutinee_to_be_expr, make.match_arm_list(arms));
-                match_expr.indent(IndentLevel::from_node(if_expr.syntax()));
-                match_expr.into()
+                let arms = cond_bodies.into_iter().map(make_match_arm).chain(iter::once(else_arm));
+                let match_expr = make::expr_match(scrutinee_to_be_expr, make::match_arm_list(arms));
+                match_expr.indent(IndentLevel::from_node(if_expr.syntax()))
             };
 
             let has_preceding_if_expr =
                 if_expr.syntax().parent().is_some_and(|it| ast::IfExpr::can_cast(it.kind()));
             let expr = if has_preceding_if_expr {
                 // make sure we replace the `else if let ...` with a block so we don't end up with `else expr`
-                make.block_expr([], Some(match_expr)).into()
+                make::block_expr(None, Some(match_expr)).into()
             } else {
                 match_expr
             };
-
-            let mut editor = builder.make_editor(if_expr.syntax());
-            editor.replace(if_expr.syntax(), expr.syntax());
-            editor.add_mappings(make.finish_with_mappings());
-            builder.add_file_edits(ctx.file_id(), editor);
+            edit.replace_ast::<ast::Expr>(if_expr.into(), expr);
         },
     )
 }
 
 fn make_else_arm(
     ctx: &AssistContext<'_>,
-    make: &SyntaxFactory,
     else_block: Option<ast::BlockExpr>,
     conditionals: &[(Either<ast::Pat, ast::Expr>, ast::BlockExpr)],
 ) -> ast::MatchArm {
     let (pattern, expr) = if let Some(else_block) = else_block {
         let pattern = match conditionals {
-            [(Either::Right(_), _)] => make.literal_pat("false").into(),
+            [(Either::Right(_), _)] => make::literal_pat("false").into(),
             [(Either::Left(pat), _)] => match ctx
                 .sema
                 .type_of_pat(pat)
@@ -165,24 +164,24 @@ fn make_else_arm(
                     if does_pat_match_variant(pat, &it.sad_pattern()) {
                         it.happy_pattern_wildcard()
                     } else if does_pat_variant_nested_or_literal(ctx, pat) {
-                        make.wildcard_pat().into()
+                        make::wildcard_pat().into()
                     } else {
                         it.sad_pattern()
                     }
                 }
-                None => make.wildcard_pat().into(),
+                None => make::wildcard_pat().into(),
             },
-            _ => make.wildcard_pat().into(),
+            _ => make::wildcard_pat().into(),
         };
         (pattern, unwrap_trivial_block(else_block))
     } else {
         let pattern = match conditionals {
-            [(Either::Right(_), _)] => make.literal_pat("false").into(),
-            _ => make.wildcard_pat().into(),
+            [(Either::Right(_), _)] => make::literal_pat("false").into(),
+            _ => make::wildcard_pat().into(),
         };
-        (pattern, make.expr_unit())
+        (pattern, make::expr_unit())
     };
-    make.match_arm(pattern, None, expr)
+    make::match_arm(iter::once(pattern), None, expr)
 }
 
 // Assist: replace_match_with_if_let
@@ -248,21 +247,21 @@ pub(crate) fn replace_match_with_if_let(acc: &mut Assists, ctx: &AssistContext<'
         }
         _ => " let",
     };
+    let target = match_expr.syntax().text_range();
     acc.add(
         AssistId("replace_match_with_if_let", AssistKind::RefactorRewrite),
         format!("Replace match with if{let_}"),
-        match_expr.syntax().text_range(),
-        move |builder| {
-            let make = SyntaxFactory::new();
-            let make_block_expr = |expr: ast::Expr| {
+        target,
+        move |edit| {
+            fn make_block_expr(expr: ast::Expr) -> ast::BlockExpr {
                 // Blocks with modifiers (unsafe, async, etc.) are parsed as BlockExpr, but are
                 // formatted without enclosing braces. If we encounter such block exprs,
                 // wrap them in another BlockExpr.
                 match expr {
                     ast::Expr::BlockExpr(block) if block.modifier().is_none() => block,
-                    expr => make.block_expr([], Some(expr)),
+                    expr => make::block_expr(iter::empty(), Some(expr)),
                 }
-            };
+            }
 
             let condition = match if_let_pat {
                 ast::Pat::LiteralPat(p)
@@ -273,25 +272,20 @@ pub(crate) fn replace_match_with_if_let(acc: &mut Assists, ctx: &AssistContext<'
                 ast::Pat::LiteralPat(p)
                     if p.literal().is_some_and(|it| it.token().kind() == T![false]) =>
                 {
-                    make.expr_prefix(T![!], scrutinee).into()
+                    make::expr_prefix(T![!], scrutinee)
                 }
-                _ => make.expr_let(if_let_pat, scrutinee).into(),
+                _ => make::expr_let(if_let_pat, scrutinee).into(),
             };
-            let then_expr = then_expr.clone_for_update();
-            then_expr.reindent_to(IndentLevel::single());
-            let then_block = make_block_expr(then_expr);
+            let then_block = make_block_expr(then_expr.reset_indent());
             let else_expr = if is_empty_expr(&else_expr) { None } else { Some(else_expr) };
-            let if_let_expr = make.expr_if(
+            let if_let_expr = make::expr_if(
                 condition,
                 then_block,
                 else_expr.map(make_block_expr).map(ast::ElseBranch::Block),
-            );
-            if_let_expr.indent(IndentLevel::from_node(match_expr.syntax()));
+            )
+            .indent(IndentLevel::from_node(match_expr.syntax()));
 
-            let mut editor = builder.make_editor(match_expr.syntax());
-            editor.replace(match_expr.syntax(), if_let_expr.syntax());
-            editor.add_mappings(make.finish_with_mappings());
-            builder.add_file_edits(ctx.file_id(), editor);
+            edit.replace_ast::<ast::Expr>(match_expr.into(), if_let_expr);
         },
     )
 }
diff --git a/crates/ide-assists/src/handlers/replace_let_with_if_let.rs b/crates/ide-assists/src/handlers/replace_let_with_if_let.rs
index c071d3022d..c2be4593b9 100644
--- a/crates/ide-assists/src/handlers/replace_let_with_if_let.rs
+++ b/crates/ide-assists/src/handlers/replace_let_with_if_let.rs
@@ -1,6 +1,12 @@
+use std::iter::once;
+
 use ide_db::ty_filter::TryEnum;
 use syntax::{
-    ast::{self, edit::IndentLevel, edit_in_place::Indent, syntax_factory::SyntaxFactory},
+    ast::{
+        self,
+        edit::{AstNodeEdit, IndentLevel},
+        make,
+    },
     AstNode, T,
 };
 
@@ -41,9 +47,7 @@ pub(crate) fn replace_let_with_if_let(acc: &mut Assists, ctx: &AssistContext<'_>
         AssistId("replace_let_with_if_let", AssistKind::RefactorRewrite),
         "Replace let with if let",
         target,
-        |builder| {
-            let mut editor = builder.make_editor(let_stmt.syntax());
-            let make = SyntaxFactory::new();
+        |edit| {
             let ty = ctx.sema.type_of_expr(&init);
             let happy_variant = ty
                 .and_then(|ty| TryEnum::from_ty(&ctx.sema, &ty.adjusted()))
@@ -51,18 +55,17 @@ pub(crate) fn replace_let_with_if_let(acc: &mut Assists, ctx: &AssistContext<'_>
             let pat = match happy_variant {
                 None => original_pat,
                 Some(var_name) => {
-                    make.tuple_struct_pat(make.ident_path(var_name), [original_pat]).into()
+                    make::tuple_struct_pat(make::ext::ident_path(var_name), once(original_pat))
+                        .into()
                 }
             };
 
-            let block = make.block_expr([], None);
-            block.indent(IndentLevel::from_node(let_stmt.syntax()));
-            let if_expr = make.expr_if(make.expr_let(pat, init).into(), block, None);
-            let if_stmt = make.expr_stmt(if_expr.into());
+            let block =
+                make::ext::empty_block_expr().indent(IndentLevel::from_node(let_stmt.syntax()));
+            let if_ = make::expr_if(make::expr_let(pat, init).into(), block, None);
+            let stmt = make::expr_stmt(if_);
 
-            editor.replace(let_stmt.syntax(), if_stmt.syntax());
-            editor.add_mappings(make.finish_with_mappings());
-            builder.add_file_edits(ctx.file_id(), editor);
+            edit.replace_ast(ast::Stmt::from(let_stmt), ast::Stmt::from(stmt));
         },
     )
 }
diff --git a/crates/ide-assists/src/handlers/replace_try_expr_with_match.rs b/crates/ide-assists/src/handlers/replace_try_expr_with_match.rs
index 88b50543dd..2e26f59d03 100644
--- a/crates/ide-assists/src/handlers/replace_try_expr_with_match.rs
+++ b/crates/ide-assists/src/handlers/replace_try_expr_with_match.rs
@@ -71,17 +71,19 @@ pub(crate) fn replace_try_expr_with_match(
             };
 
             let happy_arm = make::match_arm(
-                try_enum.happy_pattern(make::ident_pat(false, false, make::name("it")).into()),
+                iter::once(
+                    try_enum.happy_pattern(make::ident_pat(false, false, make::name("it")).into()),
+                ),
                 None,
                 make::expr_path(make::ext::ident_path("it")),
             );
-            let sad_arm = make::match_arm(sad_pat, None, sad_expr);
+            let sad_arm = make::match_arm(iter::once(sad_pat), None, sad_expr);
 
             let match_arm_list = make::match_arm_list([happy_arm, sad_arm]);
 
             let expr_match = make::expr_match(expr, match_arm_list)
                 .indent(IndentLevel::from_node(qm_kw_parent.syntax()));
-            edit.replace_ast::<ast::Expr>(qm_kw_parent.into(), expr_match.into());
+            edit.replace_ast::<ast::Expr>(qm_kw_parent.into(), expr_match);
         },
     )
 }
diff --git a/crates/ide-assists/src/handlers/unmerge_match_arm.rs b/crates/ide-assists/src/handlers/unmerge_match_arm.rs
index 6b9f661d4d..c6cffb5434 100644
--- a/crates/ide-assists/src/handlers/unmerge_match_arm.rs
+++ b/crates/ide-assists/src/handlers/unmerge_match_arm.rs
@@ -54,9 +54,13 @@ pub(crate) fn unmerge_match_arm(acc: &mut Assists, ctx: &AssistContext<'_>) -> O
             let pats_after = pipe_token
                 .siblings_with_tokens(Direction::Next)
                 .filter_map(|it| ast::Pat::cast(it.into_node()?));
-            let new_pat = make::or_pat(pats_after, or_pat.leading_pipe().is_some());
-            let new_match_arm =
-                make::match_arm(new_pat, match_arm.guard(), match_arm_body).clone_for_update();
+            // FIXME: We should add a leading pipe if the original arm has one.
+            let new_match_arm = make::match_arm(
+                pats_after,
+                match_arm.guard().and_then(|guard| guard.condition()),
+                match_arm_body,
+            )
+            .clone_for_update();
 
             let mut pipe_index = pipe_token.index();
             if pipe_token
diff --git a/crates/ide-assists/src/handlers/unwrap_block.rs b/crates/ide-assists/src/handlers/unwrap_block.rs
index fd37140e9c..f3e7f5f416 100644
--- a/crates/ide-assists/src/handlers/unwrap_block.rs
+++ b/crates/ide-assists/src/handlers/unwrap_block.rs
@@ -61,7 +61,7 @@ pub(crate) fn unwrap_block(acc: &mut Assists, ctx: &AssistContext<'_>) -> Option
                 }
             }
             None => {
-                let empty_tuple = make::ext::expr_unit();
+                let empty_tuple = make::expr_tuple([]);
                 make::let_stmt(pattern, ty, Some(empty_tuple)).to_string()
             }
         };
diff --git a/crates/ide-assists/src/utils.rs b/crates/ide-assists/src/utils.rs
index 78ff441791..e20c4ef09e 100644
--- a/crates/ide-assists/src/utils.rs
+++ b/crates/ide-assists/src/utils.rs
@@ -246,7 +246,7 @@ pub(crate) fn vis_offset(node: &SyntaxNode) -> TextSize {
 }
 
 pub(crate) fn invert_boolean_expression(expr: ast::Expr) -> ast::Expr {
-    invert_special_case(&expr).unwrap_or_else(|| make::expr_prefix(T![!], expr).into())
+    invert_special_case(&expr).unwrap_or_else(|| make::expr_prefix(T![!], expr))
 }
 
 fn invert_special_case(expr: &ast::Expr) -> Option<ast::Expr> {
@@ -262,7 +262,7 @@ fn invert_special_case(expr: &ast::Expr) -> Option<ast::Expr> {
                 T![>] => T![<=],
                 T![>=] => T![<],
                 // Parenthesize other expressions before prefixing `!`
-                _ => return Some(make::expr_prefix(T![!], make::expr_paren(expr.clone())).into()),
+                _ => return Some(make::expr_prefix(T![!], make::expr_paren(expr.clone()))),
             };
             ted::replace(op_token, make::token(rev_token));
             Some(bin.into())
diff --git a/crates/ide-assists/src/utils/gen_trait_fn_body.rs b/crates/ide-assists/src/utils/gen_trait_fn_body.rs
index a9a889acc2..75caf6d49f 100644
--- a/crates/ide-assists/src/utils/gen_trait_fn_body.rs
+++ b/crates/ide-assists/src/utils/gen_trait_fn_body.rs
@@ -66,7 +66,7 @@ fn gen_clone_impl(adt: &ast::Adt, func: &ast::Fn) -> Option<()> {
                         let pat = make::record_pat(variant_name.clone(), pats.into_iter());
                         let fields = make::record_expr_field_list(fields);
                         let record_expr = make::record_expr(variant_name, fields).into();
-                        arms.push(make::match_arm(pat.into(), None, record_expr));
+                        arms.push(make::match_arm(Some(pat.into()), None, record_expr));
                     }
 
                     // => match self { Self::Name(arg1) => Self::Name(arg1.clone()) }
@@ -84,21 +84,21 @@ fn gen_clone_impl(adt: &ast::Adt, func: &ast::Fn) -> Option<()> {
                         let pat = make::tuple_struct_pat(variant_name.clone(), pats.into_iter());
                         let struct_name = make::expr_path(variant_name);
                         let tuple_expr = make::expr_call(struct_name, make::arg_list(fields));
-                        arms.push(make::match_arm(pat.into(), None, tuple_expr));
+                        arms.push(make::match_arm(Some(pat.into()), None, tuple_expr));
                     }
 
                     // => match self { Self::Name => Self::Name }
                     None => {
                         let pattern = make::path_pat(variant_name.clone());
                         let variant_expr = make::expr_path(variant_name);
-                        arms.push(make::match_arm(pattern, None, variant_expr));
+                        arms.push(make::match_arm(Some(pattern), None, variant_expr));
                     }
                 }
             }
 
             let match_target = make::expr_path(make::ext::ident_path("self"));
             let list = make::match_arm_list(arms).indent(ast::edit::IndentLevel(1));
-            make::expr_match(match_target, list).into()
+            make::expr_match(match_target, list)
         }
         ast::Adt::Struct(strukt) => {
             match strukt.field_list() {
@@ -190,7 +190,7 @@ fn gen_debug_impl(adt: &ast::Adt, func: &ast::Fn) -> Option<()> {
 
                         // => MyStruct { fields.. } => f.debug_struct("MyStruct")...finish(),
                         let pat = make::record_pat(variant_name.clone(), pats.into_iter());
-                        arms.push(make::match_arm(pat.into(), None, expr));
+                        arms.push(make::match_arm(Some(pat.into()), None, expr));
                     }
                     Some(ast::FieldList::TupleFieldList(list)) => {
                         // => f.debug_tuple(name)
@@ -223,7 +223,7 @@ fn gen_debug_impl(adt: &ast::Adt, func: &ast::Fn) -> Option<()> {
 
                         // => MyStruct (fields..) => f.debug_tuple("MyStruct")...finish(),
                         let pat = make::tuple_struct_pat(variant_name.clone(), pats.into_iter());
-                        arms.push(make::match_arm(pat.into(), None, expr));
+                        arms.push(make::match_arm(Some(pat.into()), None, expr));
                     }
                     None => {
                         let fmt_string = make::expr_literal(&(format!("\"{name}\""))).into();
@@ -232,7 +232,7 @@ fn gen_debug_impl(adt: &ast::Adt, func: &ast::Fn) -> Option<()> {
                         let macro_call = make::expr_macro_call(macro_name, args);
 
                         let variant_name = make::path_pat(variant_name);
-                        arms.push(make::match_arm(variant_name, None, macro_call));
+                        arms.push(make::match_arm(Some(variant_name), None, macro_call));
                     }
                 }
             }
@@ -241,7 +241,7 @@ fn gen_debug_impl(adt: &ast::Adt, func: &ast::Fn) -> Option<()> {
             let list = make::match_arm_list(arms).indent(ast::edit::IndentLevel(1));
             let match_expr = make::expr_match(match_target, list);
 
-            let body = make::block_expr(None, Some(match_expr.into()));
+            let body = make::block_expr(None, Some(match_expr));
             let body = body.indent(ast::edit::IndentLevel(1));
             ted::replace(func.body()?.syntax(), body.clone_for_update().syntax());
             Some(())
@@ -485,7 +485,7 @@ fn gen_partial_eq(adt: &ast::Adt, func: &ast::Fn, trait_ref: Option<TraitRef>) -
                         let tuple = make::tuple_pat(vec![left.into(), right.into()]);
 
                         if let Some(expr) = expr {
-                            arms.push(make::match_arm(tuple.into(), None, expr));
+                            arms.push(make::match_arm(Some(tuple.into()), None, expr));
                         }
                     }
 
@@ -518,7 +518,7 @@ fn gen_partial_eq(adt: &ast::Adt, func: &ast::Fn, trait_ref: Option<TraitRef>) -
                         let tuple = make::tuple_pat(vec![left.into(), right.into()]);
 
                         if let Some(expr) = expr {
-                            arms.push(make::match_arm(tuple.into(), None, expr));
+                            arms.push(make::match_arm(Some(tuple.into()), None, expr));
                         }
                     }
                     None => continue,
@@ -538,12 +538,12 @@ fn gen_partial_eq(adt: &ast::Adt, func: &ast::Fn, trait_ref: Option<TraitRef>) -
                         } else {
                             eq_check
                         };
-                        arms.push(make::match_arm(lhs, None, rhs));
+                        arms.push(make::match_arm(Some(lhs), None, rhs));
                     }
 
-                    let match_target = make::expr_tuple([lhs_name, rhs_name]).into();
+                    let match_target = make::expr_tuple(vec![lhs_name, rhs_name]);
                     let list = make::match_arm_list(arms).indent(ast::edit::IndentLevel(1));
-                    make::expr_match(match_target, list).into()
+                    make::expr_match(match_target, list)
                 }
             };
 
@@ -599,15 +599,15 @@ fn gen_partial_ord(adt: &ast::Adt, func: &ast::Fn, trait_ref: Option<TraitRef>)
         let variant_name =
             make::path_pat(make::ext::path_from_idents(["core", "cmp", "Ordering", "Equal"])?);
         let lhs = make::tuple_struct_pat(make::ext::path_from_idents(["Some"])?, [variant_name]);
-        arms.push(make::match_arm(lhs.into(), None, make::expr_empty_block()));
+        arms.push(make::match_arm(Some(lhs.into()), None, make::expr_empty_block()));
 
         arms.push(make::match_arm(
-            make::ident_pat(false, false, make::name("ord")).into(),
+            [make::ident_pat(false, false, make::name("ord")).into()],
             None,
             make::expr_return(Some(make::expr_path(make::ext::ident_path("ord")))),
         ));
         let list = make::match_arm_list(arms).indent(ast::edit::IndentLevel(1));
-        Some(make::expr_stmt(make::expr_match(match_target, list).into()).into())
+        Some(make::expr_stmt(make::expr_match(match_target, list)).into())
     }
 
     fn gen_partial_cmp_call(lhs: ast::Expr, rhs: ast::Expr) -> ast::Expr {
diff --git a/crates/ide-assists/src/utils/ref_field_expr.rs b/crates/ide-assists/src/utils/ref_field_expr.rs
index d434872ea5..e95b291dd7 100644
--- a/crates/ide-assists/src/utils/ref_field_expr.rs
+++ b/crates/ide-assists/src/utils/ref_field_expr.rs
@@ -121,7 +121,7 @@ impl RefData {
     /// Derefs `expr` and wraps it in parens if necessary
     pub(crate) fn wrap_expr(&self, mut expr: ast::Expr) -> ast::Expr {
         if self.needs_deref {
-            expr = make::expr_prefix(T![*], expr).into();
+            expr = make::expr_prefix(T![*], expr);
         }
 
         if self.needs_parentheses {
diff --git a/crates/ide-completion/src/completions/env_vars.rs b/crates/ide-completion/src/completions/env_vars.rs
index 40af5203e9..0b6790d42a 100644
--- a/crates/ide-completion/src/completions/env_vars.rs
+++ b/crates/ide-completion/src/completions/env_vars.rs
@@ -68,40 +68,43 @@ pub(crate) fn complete_cargo_env_vars(
 mod tests {
     use crate::tests::{check_edit, completion_list};
 
-    #[test]
-    fn completes_env_variable_in_env() {
+    fn check(macro_name: &str) {
         check_edit(
             "CARGO_BIN_NAME",
-            r#"
-//- minicore: env
-fn main() {
-    let foo = env!("CAR$0");
-}
-        "#,
-            r#"
-fn main() {
-    let foo = env!("CARGO_BIN_NAME");
-}
-        "#,
+            &format!(
+                r#"
+            #[rustc_builtin_macro]
+            macro {macro_name} {{
+                ($var:literal) => {{ 0 }}
+            }}
+
+            fn main() {{
+                let foo = {macro_name}!("CAR$0");
+            }}
+        "#
+            ),
+            &format!(
+                r#"
+            #[rustc_builtin_macro]
+            macro {macro_name} {{
+                ($var:literal) => {{ 0 }}
+            }}
+
+            fn main() {{
+                let foo = {macro_name}!("CARGO_BIN_NAME");
+            }}
+        "#
+            ),
         );
     }
+    #[test]
+    fn completes_env_variable_in_env() {
+        check("env")
+    }
 
     #[test]
     fn completes_env_variable_in_option_env() {
-        check_edit(
-            "CARGO_BIN_NAME",
-            r#"
-//- minicore: env
-fn main() {
-    let foo = option_env!("CAR$0");
-}
-        "#,
-            r#"
-fn main() {
-    let foo = option_env!("CARGO_BIN_NAME");
-}
-        "#,
-        );
+        check("option_env");
     }
 
     #[test]
diff --git a/crates/ide-completion/src/completions/postfix.rs b/crates/ide-completion/src/completions/postfix.rs
index 5bdc320d57..7b57eea052 100644
--- a/crates/ide-completion/src/completions/postfix.rs
+++ b/crates/ide-completion/src/completions/postfix.rs
@@ -303,7 +303,7 @@ fn include_references(initial_element: &ast::Expr) -> (ast::Expr, ast::Expr) {
 
         resulting_element = ast::Expr::from(parent_deref_element);
 
-        new_element_opt = make::expr_prefix(syntax::T![*], new_element_opt).into();
+        new_element_opt = make::expr_prefix(syntax::T![*], new_element_opt);
     }
 
     if let Some(first_ref_expr) = resulting_element.syntax().parent().and_then(ast::RefExpr::cast) {
diff --git a/crates/mbe/src/expander/transcriber.rs b/crates/mbe/src/expander/transcriber.rs
index acab989437..9255c5a689 100644
--- a/crates/mbe/src/expander/transcriber.rs
+++ b/crates/mbe/src/expander/transcriber.rs
@@ -38,10 +38,7 @@ impl<'t> Bindings<'t> {
             nesting_state.hit = true;
             b = match b {
                 Binding::Fragment(_) => break,
-                Binding::Missing(_) => {
-                    nesting_state.at_end = true;
-                    break;
-                }
+                Binding::Missing(_) => break,
                 Binding::Nested(bs) => bs.get(nesting_state.idx).ok_or_else(|| {
                     nesting_state.at_end = true;
                     binding_err!("could not find nested binding `{name}`")
diff --git a/crates/project-model/src/cargo_workspace.rs b/crates/project-model/src/cargo_workspace.rs
index 4d906c2aeb..e4a6113462 100644
--- a/crates/project-model/src/cargo_workspace.rs
+++ b/crates/project-model/src/cargo_workspace.rs
@@ -92,6 +92,8 @@ pub struct CargoConfig {
     pub sysroot_src: Option<AbsPathBuf>,
     /// rustc private crate source
     pub rustc_source: Option<RustLibSource>,
+    /// Extra includes to add to the VFS.
+    pub extra_includes: Vec<AbsPathBuf>,
     pub cfg_overrides: CfgOverrides,
     /// Invoke `cargo check` through the RUSTC_WRAPPER.
     pub wrap_rustc_in_build_scripts: bool,
diff --git a/crates/project-model/src/workspace.rs b/crates/project-model/src/workspace.rs
index a345c6bcce..465a1ad0ec 100644
--- a/crates/project-model/src/workspace.rs
+++ b/crates/project-model/src/workspace.rs
@@ -63,6 +63,8 @@ pub struct ProjectWorkspace {
     pub target_layout: TargetLayoutLoadResult,
     /// A set of cfg overrides for this workspace.
     pub cfg_overrides: CfgOverrides,
+    /// Additional includes to add for the VFS.
+    pub extra_includes: Vec<AbsPathBuf>,
 }
 
 #[derive(Clone)]
@@ -104,7 +106,15 @@ pub enum ProjectWorkspaceKind {
 impl fmt::Debug for ProjectWorkspace {
     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
         // Make sure this isn't too verbose.
-        let Self { kind, sysroot, rustc_cfg, toolchain, target_layout, cfg_overrides } = self;
+        let Self {
+            kind,
+            sysroot,
+            rustc_cfg,
+            toolchain,
+            target_layout,
+            cfg_overrides,
+            extra_includes,
+        } = self;
         match kind {
             ProjectWorkspaceKind::Cargo { cargo, error: _, build_scripts, rustc, set_test } => f
                 .debug_struct("Cargo")
@@ -117,6 +127,7 @@ impl fmt::Debug for ProjectWorkspace {
                 )
                 .field("n_rustc_cfg", &rustc_cfg.len())
                 .field("n_cfg_overrides", &cfg_overrides.len())
+                .field("n_extra_includes", &extra_includes.len())
                 .field("toolchain", &toolchain)
                 .field("data_layout", &target_layout)
                 .field("set_test", set_test)
@@ -130,7 +141,8 @@ impl fmt::Debug for ProjectWorkspace {
                     .field("n_rustc_cfg", &rustc_cfg.len())
                     .field("toolchain", &toolchain)
                     .field("data_layout", &target_layout)
-                    .field("n_cfg_overrides", &cfg_overrides.len());
+                    .field("n_cfg_overrides", &cfg_overrides.len())
+                    .field("n_extra_includes", &extra_includes.len());
 
                 debug_struct.finish()
             }
@@ -144,6 +156,7 @@ impl fmt::Debug for ProjectWorkspace {
                 .field("toolchain", &toolchain)
                 .field("data_layout", &target_layout)
                 .field("n_cfg_overrides", &cfg_overrides.len())
+                .field("n_extra_includes", &extra_includes.len())
                 .field("set_test", set_test)
                 .finish(),
         }
@@ -320,6 +333,7 @@ impl ProjectWorkspace {
             cfg_overrides,
             toolchain,
             target_layout: data_layout.map(Arc::from).map_err(|it| Arc::from(it.to_string())),
+            extra_includes: config.extra_includes.clone(),
         })
     }
 
@@ -340,6 +354,7 @@ impl ProjectWorkspace {
             toolchain,
             target_layout: data_layout.map(Arc::from).map_err(|it| Arc::from(it.to_string())),
             cfg_overrides: config.cfg_overrides.clone(),
+            extra_includes: config.extra_includes.clone(),
         }
     }
 
@@ -399,6 +414,7 @@ impl ProjectWorkspace {
             toolchain,
             target_layout: data_layout.map(Arc::from).map_err(|it| Arc::from(it.to_string())),
             cfg_overrides: config.cfg_overrides.clone(),
+            extra_includes: config.extra_includes.clone(),
         })
     }
 
@@ -565,7 +581,13 @@ impl ProjectWorkspace {
 
                     PackageRoot {
                         is_local: krate.is_workspace_member,
-                        include: krate.include.iter().cloned().chain(build_file).collect(),
+                        include: krate
+                            .include
+                            .iter()
+                            .cloned()
+                            .chain(build_file)
+                            .chain(self.extra_includes.iter().cloned())
+                            .collect(),
                         exclude: krate.exclude.clone(),
                     }
                 })
@@ -603,6 +625,8 @@ impl ProjectWorkspace {
 
                         let mut exclude = vec![pkg_root.join(".git")];
                         if is_local {
+                            include.extend(self.extra_includes.iter().cloned());
+
                             exclude.push(pkg_root.join("target"));
                         } else {
                             exclude.push(pkg_root.join("tests"));
@@ -661,6 +685,8 @@ impl ProjectWorkspace {
 
                         let mut exclude = vec![pkg_root.join(".git")];
                         if is_local {
+                            include.extend(self.extra_includes.iter().cloned());
+
                             exclude.push(pkg_root.join("target"));
                         } else {
                             exclude.push(pkg_root.join("tests"));
diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs
index 30f0031905..28afd83e5c 100644
--- a/crates/rust-analyzer/src/config.rs
+++ b/crates/rust-analyzer/src/config.rs
@@ -728,6 +728,10 @@ config_data! {
         /// available on a nightly build.
         rustfmt_rangeFormatting_enable: bool = false,
 
+        /// Additional paths to include in the VFS. Generally for code that is
+        /// generated or otherwise managed by a build system outside of Cargo,
+        /// though Cargo might be the eventual consumer.
+        vfs_extraIncludes: Vec<String> = vec![],
 
         /// Workspace symbol search kind.
         workspace_symbol_search_kind: WorkspaceSymbolSearchKindDef = WorkspaceSymbolSearchKindDef::OnlyTypes,
@@ -1926,6 +1930,13 @@ impl Config {
         });
         let sysroot_src =
             self.cargo_sysrootSrc(source_root).as_ref().map(|sysroot| self.root_path.join(sysroot));
+        let extra_includes = self
+            .vfs_extraIncludes(source_root)
+            .iter()
+            .map(String::as_str)
+            .map(AbsPathBuf::try_from)
+            .filter_map(Result::ok)
+            .collect();
 
         CargoConfig {
             all_targets: *self.cargo_allTargets(source_root),
@@ -1940,6 +1951,7 @@ impl Config {
             sysroot,
             sysroot_src,
             rustc_source,
+            extra_includes,
             cfg_overrides: project_model::CfgOverrides {
                 global: CfgDiff::new(
                     self.cargo_cfgs(source_root)
diff --git a/crates/syntax/src/ast/edit.rs b/crates/syntax/src/ast/edit.rs
index 579f3ba8b4..de40d638be 100644
--- a/crates/syntax/src/ast/edit.rs
+++ b/crates/syntax/src/ast/edit.rs
@@ -153,8 +153,8 @@ impl<N: AstNode + Clone> AstNodeEdit for N {}
 #[test]
 fn test_increase_indent() {
     let arm_list = {
-        let arm = make::match_arm(make::wildcard_pat().into(), None, make::ext::expr_unit());
-        make::match_arm_list([arm.clone(), arm])
+        let arm = make::match_arm(iter::once(make::wildcard_pat().into()), None, make::expr_unit());
+        make::match_arm_list(vec![arm.clone(), arm])
     };
     assert_eq!(
         arm_list.syntax().to_string(),
diff --git a/crates/syntax/src/ast/expr_ext.rs b/crates/syntax/src/ast/expr_ext.rs
index 93faeb40c3..9466755576 100644
--- a/crates/syntax/src/ast/expr_ext.rs
+++ b/crates/syntax/src/ast/expr_ext.rs
@@ -10,7 +10,7 @@ use crate::{
         FormatArgsArg, FormatArgsExpr, MacroDef, Static, TokenTree,
     },
     AstToken,
-    SyntaxKind::{self, *},
+    SyntaxKind::*,
     SyntaxNode, SyntaxToken, T,
 };
 
@@ -50,27 +50,6 @@ impl From<ast::IfExpr> for ElseBranch {
     }
 }
 
-impl AstNode for ElseBranch {
-    fn can_cast(kind: SyntaxKind) -> bool {
-        ast::BlockExpr::can_cast(kind) || ast::IfExpr::can_cast(kind)
-    }
-
-    fn cast(syntax: SyntaxNode) -> Option<Self> {
-        if let Some(block_expr) = ast::BlockExpr::cast(syntax.clone()) {
-            Some(Self::Block(block_expr))
-        } else {
-            ast::IfExpr::cast(syntax).map(Self::IfExpr)
-        }
-    }
-
-    fn syntax(&self) -> &SyntaxNode {
-        match self {
-            ElseBranch::Block(block_expr) => block_expr.syntax(),
-            ElseBranch::IfExpr(if_expr) => if_expr.syntax(),
-        }
-    }
-}
-
 impl ast::IfExpr {
     pub fn condition(&self) -> Option<ast::Expr> {
         // If the condition is a BlockExpr, check if the then body is missing.
diff --git a/crates/syntax/src/ast/make.rs b/crates/syntax/src/ast/make.rs
index a920fe4f35..282cbc4b3a 100644
--- a/crates/syntax/src/ast/make.rs
+++ b/crates/syntax/src/ast/make.rs
@@ -63,9 +63,6 @@ pub mod ext {
         Some(expr)
     }
 
-    pub fn expr_unit() -> ast::Expr {
-        expr_tuple([]).into()
-    }
     pub fn expr_unreachable() -> ast::Expr {
         expr_from_text("unreachable!()")
     }
@@ -549,6 +546,10 @@ pub fn hacky_block_expr(
     ast_from_text(&format!("fn f() {buf}"))
 }
 
+pub fn expr_unit() -> ast::Expr {
+    expr_from_text("()")
+}
+
 pub fn expr_literal(text: &str) -> ast::Literal {
     assert_eq!(text.trim(), text);
     ast_from_text(&format!("fn f() {{ let _ = {text}; }}"))
@@ -599,14 +600,14 @@ pub fn expr_try(expr: ast::Expr) -> ast::Expr {
 pub fn expr_await(expr: ast::Expr) -> ast::Expr {
     expr_from_text(&format!("{expr}.await"))
 }
-pub fn expr_match(expr: ast::Expr, match_arm_list: ast::MatchArmList) -> ast::MatchExpr {
+pub fn expr_match(expr: ast::Expr, match_arm_list: ast::MatchArmList) -> ast::Expr {
     expr_from_text(&format!("match {expr} {match_arm_list}"))
 }
 pub fn expr_if(
     condition: ast::Expr,
     then_branch: ast::BlockExpr,
     else_branch: Option<ast::ElseBranch>,
-) -> ast::IfExpr {
+) -> ast::Expr {
     let else_branch = match else_branch {
         Some(ast::ElseBranch::Block(block)) => format!("else {block}"),
         Some(ast::ElseBranch::IfExpr(if_expr)) => format!("else {if_expr}"),
@@ -622,7 +623,7 @@ pub fn expr_loop(block: ast::BlockExpr) -> ast::Expr {
     expr_from_text(&format!("loop {block}"))
 }
 
-pub fn expr_prefix(op: SyntaxKind, expr: ast::Expr) -> ast::PrefixExpr {
+pub fn expr_prefix(op: SyntaxKind, expr: ast::Expr) -> ast::Expr {
     let token = token(op);
     expr_from_text(&format!("{token}{expr}"))
 }
@@ -655,14 +656,14 @@ pub fn expr_field(receiver: ast::Expr, field: &str) -> ast::Expr {
 pub fn expr_paren(expr: ast::Expr) -> ast::Expr {
     expr_from_text(&format!("({expr})"))
 }
-pub fn expr_tuple(elements: impl IntoIterator<Item = ast::Expr>) -> ast::TupleExpr {
+pub fn expr_tuple(elements: impl IntoIterator<Item = ast::Expr>) -> ast::Expr {
     let expr = elements.into_iter().format(", ");
     expr_from_text(&format!("({expr})"))
 }
 pub fn expr_assignment(lhs: ast::Expr, rhs: ast::Expr) -> ast::Expr {
     expr_from_text(&format!("{lhs} = {rhs}"))
 }
-fn expr_from_text<E: Into<ast::Expr> + AstNode>(text: &str) -> E {
+fn expr_from_text(text: &str) -> ast::Expr {
     ast_from_text(&format!("const C: () = {text};"))
 }
 pub fn expr_let(pattern: ast::Pat, expr: ast::Expr) -> ast::LetExpr {
@@ -787,21 +788,15 @@ pub fn path_pat(path: ast::Path) -> ast::Pat {
     }
 }
 
-/// Returns a `Pat` if the path has just one segment, an `OrPat` otherwise.
-pub fn or_pat(pats: impl IntoIterator<Item = ast::Pat>, leading_pipe: bool) -> ast::Pat {
-    let leading_pipe = if leading_pipe { "| " } else { "" };
-    let pats = pats.into_iter().join(" | ");
-
-    return from_text(&format!("{leading_pipe}{pats}"));
-    fn from_text(text: &str) -> ast::Pat {
-        ast_from_text(&format!("fn f({text}: ())"))
-    }
-}
-
-pub fn match_arm(pat: ast::Pat, guard: Option<ast::MatchGuard>, expr: ast::Expr) -> ast::MatchArm {
+pub fn match_arm(
+    pats: impl IntoIterator<Item = ast::Pat>,
+    guard: Option<ast::Expr>,
+    expr: ast::Expr,
+) -> ast::MatchArm {
+    let pats_str = pats.into_iter().join(" | ");
     return match guard {
-        Some(guard) => from_text(&format!("{pat} {guard} => {expr}")),
-        None => from_text(&format!("{pat} => {expr}")),
+        Some(guard) => from_text(&format!("{pats_str} if {guard} => {expr}")),
+        None => from_text(&format!("{pats_str} => {expr}")),
     };
 
     fn from_text(text: &str) -> ast::MatchArm {
@@ -822,14 +817,6 @@ pub fn match_arm_with_guard(
     }
 }
 
-pub fn match_guard(condition: ast::Expr) -> ast::MatchGuard {
-    return from_text(&format!("if {condition}"));
-
-    fn from_text(text: &str) -> ast::MatchGuard {
-        ast_from_text(&format!("fn f() {{ match () {{() {text} => () }}"))
-    }
-}
-
 pub fn match_arm_list(arms: impl IntoIterator<Item = ast::MatchArm>) -> ast::MatchArmList {
     let arms_str = arms.into_iter().fold(String::new(), |mut acc, arm| {
         let needs_comma = arm.expr().is_none_or(|it| !it.is_block_like());
diff --git a/crates/syntax/src/ast/syntax_factory/constructors.rs b/crates/syntax/src/ast/syntax_factory/constructors.rs
index d62c01ba76..bea6bfeafc 100644
--- a/crates/syntax/src/ast/syntax_factory/constructors.rs
+++ b/crates/syntax/src/ast/syntax_factory/constructors.rs
@@ -1,6 +1,6 @@
 //! Wrappers over [`make`] constructors
 use crate::{
-    ast::{self, make, HasGenericArgs, HasGenericParams, HasName, HasTypeBounds, HasVisibility},
+    ast::{self, make, HasGenericParams, HasName, HasTypeBounds, HasVisibility},
     syntax_editor::SyntaxMappingBuilder,
     AstNode, NodeOrToken, SyntaxKind, SyntaxNode, SyntaxToken,
 };
@@ -12,10 +12,6 @@ impl SyntaxFactory {
         make::name(name).clone_for_update()
     }
 
-    pub fn name_ref(&self, name: &str) -> ast::NameRef {
-        make::name_ref(name).clone_for_update()
-    }
-
     pub fn ty(&self, text: &str) -> ast::Type {
         make::ty(text).clone_for_update()
     }
@@ -50,71 +46,6 @@ impl SyntaxFactory {
         ast
     }
 
-    pub fn path_segment(&self, name_ref: ast::NameRef) -> ast::PathSegment {
-        let ast = make::path_segment(name_ref.clone()).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(name_ref.syntax().clone(), ast.name_ref().unwrap().syntax().clone());
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn path_segment_generics(
-        &self,
-        name_ref: ast::NameRef,
-        generic_arg_list: ast::GenericArgList,
-    ) -> ast::PathSegment {
-        let ast::Type::PathType(path) = make::ty(&format!("{name_ref}{generic_arg_list}")) else {
-            unreachable!();
-        };
-
-        let ast = path.path().unwrap().segment().unwrap().clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(name_ref.syntax().clone(), ast.name_ref().unwrap().syntax().clone());
-            builder.map_node(
-                generic_arg_list.syntax().clone(),
-                ast.generic_arg_list().unwrap().syntax().clone(),
-            );
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn path_unqualified(&self, segment: ast::PathSegment) -> ast::Path {
-        let ast = make::path_unqualified(segment.clone()).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(segment.syntax().clone(), ast.segment().unwrap().syntax().clone());
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn path_from_segments(
-        &self,
-        segments: impl IntoIterator<Item = ast::PathSegment>,
-        is_abs: bool,
-    ) -> ast::Path {
-        let (segments, input) = iterator_input(segments);
-        let ast = make::path_from_segments(segments, is_abs).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_children(input.into_iter(), ast.segments().map(|it| it.syntax().clone()));
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
     pub fn ident_pat(&self, ref_: bool, mut_: bool, name: ast::Name) -> ast::IdentPat {
         let ast = make::ident_pat(ref_, mut_, name.clone()).clone_for_update();
 
@@ -127,32 +58,6 @@ impl SyntaxFactory {
         ast
     }
 
-    pub fn wildcard_pat(&self) -> ast::WildcardPat {
-        make::wildcard_pat().clone_for_update()
-    }
-
-    pub fn literal_pat(&self, text: &str) -> ast::LiteralPat {
-        make::literal_pat(text).clone_for_update()
-    }
-
-    pub fn tuple_struct_pat(
-        &self,
-        path: ast::Path,
-        fields: impl IntoIterator<Item = ast::Pat>,
-    ) -> ast::TupleStructPat {
-        let (fields, input) = iterator_input(fields);
-        let ast = make::tuple_struct_pat(path.clone(), fields).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(path.syntax().clone(), ast.path().unwrap().syntax().clone());
-            builder.map_children(input.into_iter(), ast.fields().map(|it| it.syntax().clone()));
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
     pub fn block_expr(
         &self,
         statements: impl IntoIterator<Item = ast::Stmt>,
@@ -193,19 +98,6 @@ impl SyntaxFactory {
         ast::BlockExpr { syntax: make::expr_empty_block().syntax().clone_for_update() }
     }
 
-    pub fn expr_tuple(&self, fields: impl IntoIterator<Item = ast::Expr>) -> ast::TupleExpr {
-        let (fields, input) = iterator_input(fields);
-        let ast = make::expr_tuple(fields).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_children(input.into_iter(), ast.fields().map(|it| it.syntax().clone()));
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
     pub fn expr_bin(&self, lhs: ast::Expr, op: ast::BinaryOp, rhs: ast::Expr) -> ast::BinExpr {
         let ast::Expr::BinExpr(ast) =
             make::expr_bin_op(lhs.clone(), op, rhs.clone()).clone_for_update()
@@ -223,10 +115,6 @@ impl SyntaxFactory {
         ast
     }
 
-    pub fn expr_literal(&self, text: &str) -> ast::Literal {
-        make::expr_literal(text).clone_for_update()
-    }
-
     pub fn expr_path(&self, path: ast::Path) -> ast::Expr {
         let ast::Expr::PathExpr(ast) = make::expr_path(path.clone()).clone_for_update() else {
             unreachable!()
@@ -241,18 +129,6 @@ impl SyntaxFactory {
         ast.into()
     }
 
-    pub fn expr_prefix(&self, op: SyntaxKind, expr: ast::Expr) -> ast::PrefixExpr {
-        let ast = make::expr_prefix(op, expr.clone()).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(expr.syntax().clone(), ast.expr().unwrap().syntax().clone());
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
     pub fn expr_ref(&self, expr: ast::Expr, exclusive: bool) -> ast::Expr {
         let ast::Expr::RefExpr(ast) = make::expr_ref(expr.clone(), exclusive).clone_for_update()
         else {
@@ -284,125 +160,6 @@ impl SyntaxFactory {
         ast
     }
 
-    pub fn expr_if(
-        &self,
-        condition: ast::Expr,
-        then_branch: ast::BlockExpr,
-        else_branch: Option<ast::ElseBranch>,
-    ) -> ast::IfExpr {
-        let ast = make::expr_if(condition.clone(), then_branch.clone(), else_branch.clone())
-            .clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(condition.syntax().clone(), ast.condition().unwrap().syntax().clone());
-            builder.map_node(
-                then_branch.syntax().clone(),
-                ast.then_branch().unwrap().syntax().clone(),
-            );
-
-            if let Some(else_branch) = else_branch {
-                builder.map_node(
-                    else_branch.syntax().clone(),
-                    ast.else_branch().unwrap().syntax().clone(),
-                );
-            }
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn expr_let(&self, pattern: ast::Pat, expr: ast::Expr) -> ast::LetExpr {
-        let ast = make::expr_let(pattern.clone(), expr.clone()).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(pattern.syntax().clone(), ast.pat().unwrap().syntax().clone());
-            builder.map_node(expr.syntax().clone(), ast.expr().unwrap().syntax().clone());
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn expr_stmt(&self, expr: ast::Expr) -> ast::ExprStmt {
-        let ast = make::expr_stmt(expr.clone()).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(expr.syntax().clone(), ast.expr().unwrap().syntax().clone());
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn expr_match(&self, expr: ast::Expr, match_arm_list: ast::MatchArmList) -> ast::MatchExpr {
-        let ast = make::expr_match(expr.clone(), match_arm_list.clone()).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(expr.syntax().clone(), ast.expr().unwrap().syntax().clone());
-            builder.map_node(
-                match_arm_list.syntax().clone(),
-                ast.match_arm_list().unwrap().syntax().clone(),
-            );
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn match_arm(
-        &self,
-        pat: ast::Pat,
-        guard: Option<ast::MatchGuard>,
-        expr: ast::Expr,
-    ) -> ast::MatchArm {
-        let ast = make::match_arm(pat.clone(), guard.clone(), expr.clone()).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(pat.syntax().clone(), ast.pat().unwrap().syntax().clone());
-            if let Some(guard) = guard {
-                builder.map_node(guard.syntax().clone(), ast.guard().unwrap().syntax().clone());
-            }
-            builder.map_node(expr.syntax().clone(), ast.expr().unwrap().syntax().clone());
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn match_guard(&self, condition: ast::Expr) -> ast::MatchGuard {
-        let ast = make::match_guard(condition.clone()).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_node(condition.syntax().clone(), ast.condition().unwrap().syntax().clone());
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
-    pub fn match_arm_list(
-        &self,
-        match_arms: impl IntoIterator<Item = ast::MatchArm>,
-    ) -> ast::MatchArmList {
-        let (match_arms, input) = iterator_input(match_arms);
-        let ast = make::match_arm_list(match_arms).clone_for_update();
-
-        if let Some(mut mapping) = self.mappings() {
-            let mut builder = SyntaxMappingBuilder::new(ast.syntax().clone());
-            builder.map_children(input.into_iter(), ast.arms().map(|it| it.syntax().clone()));
-            builder.finish(&mut mapping);
-        }
-
-        ast
-    }
-
     pub fn let_stmt(
         &self,
         pattern: ast::Pat,
@@ -746,22 +503,11 @@ impl SyntaxFactory {
         make::token(kind)
     }
 
-    pub fn whitespace(&self, text: &str) -> SyntaxToken {
+    pub fn whitespace(&self, text: &str) -> ast::SyntaxToken {
         make::tokens::whitespace(text)
     }
 }
 
-// `ext` constructors
-impl SyntaxFactory {
-    pub fn expr_unit(&self) -> ast::Expr {
-        self.expr_tuple([]).into()
-    }
-
-    pub fn ident_path(&self, ident: &str) -> ast::Path {
-        self.path_unqualified(self.path_segment(self.name_ref(ident)))
-    }
-}
-
 // We need to collect `input` here instead of taking `impl IntoIterator + Clone`,
 // because if we took `impl IntoIterator + Clone`, that could be something like an
 // `Iterator::map` with a closure that also makes use of a `SyntaxFactory` constructor.
diff --git a/crates/syntax/src/syntax_editor.rs b/crates/syntax/src/syntax_editor.rs
index b82181ae13..992a847663 100644
--- a/crates/syntax/src/syntax_editor.rs
+++ b/crates/syntax/src/syntax_editor.rs
@@ -335,7 +335,7 @@ mod tests {
     #[test]
     fn basic_usage() {
         let root = make::match_arm(
-            make::wildcard_pat().into(),
+            [make::wildcard_pat().into()],
             None,
             make::expr_tuple([
                 make::expr_bin_op(
@@ -344,8 +344,7 @@ mod tests {
                     make::expr_literal("2").into(),
                 ),
                 make::expr_literal("true").into(),
-            ])
-            .into(),
+            ]),
         );
 
         let to_wrap = root.syntax().descendants().find_map(ast::TupleExpr::cast).unwrap();
@@ -550,7 +549,7 @@ mod tests {
             None,
             None,
             make::param_list(None, []),
-            make::block_expr([], Some(make::ext::expr_unit())),
+            make::block_expr([], Some(make::expr_unit())),
             Some(make::ret_type(make::ty_unit())),
             false,
             false,
diff --git a/docs/user/generated_config.adoc b/docs/user/generated_config.adoc
index 5b86766aa8..b3d3614e22 100644
--- a/docs/user/generated_config.adoc
+++ b/docs/user/generated_config.adoc
@@ -1051,6 +1051,13 @@ Show documentation.
 --
 Specify the characters to exclude from triggering typing assists. The default trigger characters are `.`, `=`, `<`, `>`, `{`, and `(`.
 --
+[[rust-analyzer.vfs.extraIncludes]]rust-analyzer.vfs.extraIncludes (default: `[]`)::
++
+--
+Additional paths to include in the VFS. Generally for code that is
+generated or otherwise managed by a build system outside of Cargo,
+though Cargo might be the eventual consumer.
+--
 [[rust-analyzer.workspace.discoverConfig]]rust-analyzer.workspace.discoverConfig (default: `null`)::
 +
 --
diff --git a/editors/code/package.json b/editors/code/package.json
index 80246bf3fe..87afc5c281 100644
--- a/editors/code/package.json
+++ b/editors/code/package.json
@@ -2718,6 +2718,19 @@
                     }
                 }
             },
+            {
+                "title": "vfs",
+                "properties": {
+                    "rust-analyzer.vfs.extraIncludes": {
+                        "markdownDescription": "Additional paths to include in the VFS. Generally for code that is\ngenerated or otherwise managed by a build system outside of Cargo,\nthough Cargo might be the eventual consumer.",
+                        "default": [],
+                        "type": "array",
+                        "items": {
+                            "type": "string"
+                        }
+                    }
+                }
+            },
             {
                 "title": "workspace",
                 "properties": {


Test patch:
diff --git a/crates/ide-diagnostics/src/tests.rs b/crates/ide-diagnostics/src/tests.rs
index 7cf51f3d14..ec74640a54 100644
--- a/crates/ide-diagnostics/src/tests.rs
+++ b/crates/ide-diagnostics/src/tests.rs
@@ -1,7 +1,5 @@
 #![allow(clippy::print_stderr)]
 
-mod overly_long_real_world_cases;
-
 use ide_db::{
     assists::AssistResolveStrategy, base_db::SourceDatabase, LineIndexDatabase, RootDatabase,
 };
diff --git a/crates/ide-diagnostics/src/tests/overly_long_real_world_cases.rs b/crates/ide-diagnostics/src/tests/overly_long_real_world_cases.rs
deleted file mode 100644
index c6831d818a..0000000000
--- a/crates/ide-diagnostics/src/tests/overly_long_real_world_cases.rs
+++ /dev/null
@@ -1,2726 +0,0 @@
-//! Overly long excerpts of failures from real world cases, that I was too lazy to minimize.
-
-use crate::tests::check_diagnostics_with_disabled;
-
-#[test]
-fn tracing_infinite_repeat() {
-    check_diagnostics_with_disabled(
-        r#"
-//- /core.rs crate:core
-#[rustc_builtin_macro]
-#[macro_export]
-macro_rules! concat {
-($($e:expr),* $(,)?) => {{ /* compiler built-in */ }};
-}
-#[rustc_builtin_macro]
-#[macro_export]
-macro_rules! file {
-() => {
-    /* compiler built-in */
-};
-}
-#[allow_internal_unsafe]
-#[allow_internal_unstable(fmt_internals)]
-#[rustc_builtin_macro]
-#[macro_export]
-macro_rules! format_args {
-($fmt:expr) => {{ /* compiler built-in */ }};
-($fmt:expr, $($args:tt)*) => {{ /* compiler built-in */ }};
-}
-#[rustc_builtin_macro]
-#[macro_export]
-macro_rules! line {
-() => {
-    /* compiler built-in */
-};
-}
-
-//- /tracing_core.rs crate:tracing_core deps:core
-#[macro_export]
-macro_rules! identify_callsite {
-($callsite:expr) => {
-    $crate::callsite::Identifier($callsite)
-};
-}
-
-#[macro_export]
-macro_rules! metadata {
-(
-    name: $name:expr,
-    target: $target:expr,
-    level: $level:expr,
-    fields: $fields:expr,
-    callsite: $callsite:expr,
-    kind: $kind:expr
-) => {
-    $crate::metadata! {
-        name: $name,
-        target: $target,
-        level: $level,
-        fields: $fields,
-        callsite: $callsite,
-        kind: $kind,
-    }
-};
-(
-    name: $name:expr,
-    target: $target:expr,
-    level: $level:expr,
-    fields: $fields:expr,
-    callsite: $callsite:expr,
-    kind: $kind:expr,
-) => {
-    $crate::metadata::Metadata::new(
-        $name,
-        $target,
-        $level,
-        $crate::__macro_support::Option::Some($crate::__macro_support::file!()),
-        $crate::__macro_support::Option::Some($crate::__macro_support::line!()),
-        $crate::__macro_support::Option::Some($crate::__macro_support::module_path!()),
-        $crate::field::FieldSet::new($fields, $crate::identify_callsite!($callsite)),
-        $kind,
-    )
-};
-}
-
-//- /tracing.rs crate:tracing deps:core,tracing_core
-#[doc(hidden)]
-pub mod __macro_support {
-// Re-export the `core` functions that are used in macros. This allows
-// a crate to be named `core` and avoid name clashes.
-// See here: https://github.com/tokio-rs/tracing/issues/2761
-pub use core::{concat, file, format_args, iter::Iterator, line, option::Option};
-}
-
-#[macro_export]
-macro_rules! span {
-(target: $target:expr, parent: $parent:expr, $lvl:expr, $name:expr) => {
-    $crate::span!(target: $target, parent: $parent, $lvl, $name,)
-};
-(target: $target:expr, parent: $parent:expr, $lvl:expr, $name:expr, $($fields:tt)*) => {
-    {
-        use $crate::__macro_support::Callsite as _;
-        static __CALLSITE: $crate::__macro_support::MacroCallsite = $crate::callsite2! {
-            name: $name,
-            kind: $crate::metadata::Kind::SPAN,
-            target: $target,
-            level: $lvl,
-            fields: $($fields)*
-        };
-        let mut interest = $crate::subscriber::Interest::never();
-        if $crate::level_enabled!($lvl)
-            && { interest = __CALLSITE.interest(); !interest.is_never() }
-            && $crate::__macro_support::__is_enabled(__CALLSITE.metadata(), interest)
-        {
-            let meta = __CALLSITE.metadata();
-            // span with explicit parent
-            $crate::Span::child_of(
-                $parent,
-                meta,
-                &$crate::valueset!(meta.fields(), $($fields)*),
-            )
-        } else {
-            let span = $crate::__macro_support::__disabled_span(__CALLSITE.metadata());
-            $crate::if_log_enabled! { $lvl, {
-                span.record_all(&$crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*));
-            }};
-            span
-        }
-    }
-};
-(target: $target:expr, $lvl:expr, $name:expr, $($fields:tt)*) => {
-    {
-        use $crate::__macro_support::Callsite as _;
-        static __CALLSITE: $crate::callsite::DefaultCallsite = $crate::callsite2! {
-            name: $name,
-            kind: $crate::metadata::Kind::SPAN,
-            target: $target,
-            level: $lvl,
-            fields: $($fields)*
-        };
-        let mut interest = $crate::subscriber::Interest::never();
-        if $crate::level_enabled!($lvl)
-            && { interest = __CALLSITE.interest(); !interest.is_never() }
-            && $crate::__macro_support::__is_enabled(__CALLSITE.metadata(), interest)
-        {
-            let meta = __CALLSITE.metadata();
-            // span with contextual parent
-            $crate::Span::new(
-                meta,
-                &$crate::valueset!(meta.fields(), $($fields)*),
-            )
-        } else {
-            let span = $crate::__macro_support::__disabled_span(__CALLSITE.metadata());
-            $crate::if_log_enabled! { $lvl, {
-                span.record_all(&$crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*));
-            }};
-            span
-        }
-    }
-};
-(target: $target:expr, parent: $parent:expr, $lvl:expr, $name:expr) => {
-    $crate::span!(target: $target, parent: $parent, $lvl, $name,)
-};
-(parent: $parent:expr, $lvl:expr, $name:expr, $($fields:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        $name,
-        $($fields)*
-    )
-};
-(parent: $parent:expr, $lvl:expr, $name:expr) => {
-    $crate::span!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        $name,
-    )
-};
-(target: $target:expr, $lvl:expr, $name:expr, $($fields:tt)*) => {
-    $crate::span!(
-        target: $target,
-        $lvl,
-        $name,
-        $($fields)*
-    )
-};
-(target: $target:expr, $lvl:expr, $name:expr) => {
-    $crate::span!(target: $target, $lvl, $name,)
-};
-($lvl:expr, $name:expr, $($fields:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        $lvl,
-        $name,
-        $($fields)*
-    )
-};
-($lvl:expr, $name:expr) => {
-    $crate::span!(
-        target: module_path!(),
-        $lvl,
-        $name,
-    )
-};
-}
-
-#[macro_export]
-macro_rules! trace_span {
-(target: $target:expr, parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        parent: $parent,
-        $crate::Level::TRACE,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, parent: $parent:expr, $name:expr) => {
-    $crate::trace_span!(target: $target, parent: $parent, $name,)
-};
-(parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        $name,
-        $($field)*
-    )
-};
-(parent: $parent:expr, $name:expr) => {
-    $crate::trace_span!(parent: $parent, $name,)
-};
-(target: $target:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        $crate::Level::TRACE,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, $name:expr) => {
-    $crate::trace_span!(target: $target, $name,)
-};
-($name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        $name,
-        $($field)*
-    )
-};
-($name:expr) => { $crate::trace_span!($name,) };
-}
-
-#[macro_export]
-macro_rules! debug_span {
-(target: $target:expr, parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        parent: $parent,
-        $crate::Level::DEBUG,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, parent: $parent:expr, $name:expr) => {
-    $crate::debug_span!(target: $target, parent: $parent, $name,)
-};
-(parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        $name,
-        $($field)*
-    )
-};
-(parent: $parent:expr, $name:expr) => {
-    $crate::debug_span!(parent: $parent, $name,)
-};
-(target: $target:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        $crate::Level::DEBUG,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, $name:expr) => {
-    $crate::debug_span!(target: $target, $name,)
-};
-($name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        $name,
-        $($field)*
-    )
-};
-($name:expr) => {$crate::debug_span!($name,)};
-}
-
-#[macro_export]
-macro_rules! info_span {
-(target: $target:expr, parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        parent: $parent,
-        $crate::Level::INFO,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, parent: $parent:expr, $name:expr) => {
-    $crate::info_span!(target: $target, parent: $parent, $name,)
-};
-(parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        $name,
-        $($field)*
-    )
-};
-(parent: $parent:expr, $name:expr) => {
-    $crate::info_span!(parent: $parent, $name,)
-};
-(target: $target:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        $crate::Level::INFO,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, $name:expr) => {
-    $crate::info_span!(target: $target, $name,)
-};
-($name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        $name,
-        $($field)*
-    )
-};
-($name:expr) => {$crate::info_span!($name,)};
-}
-
-#[macro_export]
-macro_rules! warn_span {
-(target: $target:expr, parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        parent: $parent,
-        $crate::Level::WARN,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, parent: $parent:expr, $name:expr) => {
-    $crate::warn_span!(target: $target, parent: $parent, $name,)
-};
-(parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        $name,
-        $($field)*
-    )
-};
-(parent: $parent:expr, $name:expr) => {
-    $crate::warn_span!(parent: $parent, $name,)
-};
-(target: $target:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        $crate::Level::WARN,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, $name:expr) => {
-    $crate::warn_span!(target: $target, $name,)
-};
-($name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        $name,
-        $($field)*
-    )
-};
-($name:expr) => {$crate::warn_span!($name,)};
-}
-
-#[macro_export]
-macro_rules! error_span {
-(target: $target:expr, parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        parent: $parent,
-        $crate::Level::ERROR,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, parent: $parent:expr, $name:expr) => {
-    $crate::error_span!(target: $target, parent: $parent, $name,)
-};
-(parent: $parent:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        $name,
-        $($field)*
-    )
-};
-(parent: $parent:expr, $name:expr) => {
-    $crate::error_span!(parent: $parent, $name,)
-};
-(target: $target:expr, $name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: $target,
-        $crate::Level::ERROR,
-        $name,
-        $($field)*
-    )
-};
-(target: $target:expr, $name:expr) => {
-    $crate::error_span!(target: $target, $name,)
-};
-($name:expr, $($field:tt)*) => {
-    $crate::span!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        $name,
-        $($field)*
-    )
-};
-($name:expr) => {$crate::error_span!($name,)};
-}
-
-#[macro_export]
-macro_rules! event {
-// Name / target / parent.
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $lvl:expr, { $($fields:tt)* } )=> ({
-    use $crate::__macro_support::Callsite as _;
-    static __CALLSITE: $crate::__macro_support::MacroCallsite = $crate::callsite2! {
-        name: $name,
-        kind: $crate::metadata::Kind::EVENT,
-        target: $target,
-        level: $lvl,
-        fields: $($fields)*
-    };
-
-    let enabled = $crate::level_enabled!($lvl) && {
-        let interest = __CALLSITE.interest();
-        !interest.is_never() && $crate::__macro_support::__is_enabled(__CALLSITE.metadata(), interest)
-    };
-    if enabled {
-        (|value_set: $crate::field::ValueSet| {
-            $crate::__tracing_log!(
-                $lvl,
-                __CALLSITE,
-                &value_set
-            );
-            let meta = __CALLSITE.metadata();
-            // event with explicit parent
-            $crate::Event::child_of(
-                $parent,
-                meta,
-                &value_set
-            );
-        })($crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*));
-    } else {
-        $crate::__tracing_log!(
-            $lvl,
-            __CALLSITE,
-            &$crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*)
-        );
-    }
-});
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        name: $name,
-        target: $target,
-        parent: $parent,
-        $lvl,
-        { message = $crate::__macro_support::format_args!($($arg)+), $($fields)* }
-    )
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $lvl:expr, $($k:ident).+ = $($fields:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $lvl, { $($k).+ = $($fields)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $lvl:expr, $($arg:tt)+) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $lvl, { $($arg)+ })
-);
-
-// Name / target.
-(name: $name:expr, target: $target:expr, $lvl:expr, { $($fields:tt)* } )=> ({
-    use $crate::__macro_support::Callsite as _;
-    static __CALLSITE: $crate::__macro_support::MacroCallsite = $crate::callsite2! {
-        name: $name,
-        kind: $crate::metadata::Kind::EVENT,
-        target: $target,
-        level: $lvl,
-        fields: $($fields)*
-    };
-    let enabled = $crate::level_enabled!($lvl) && {
-        let interest = __CALLSITE.interest();
-        !interest.is_never() && $crate::__macro_support::__is_enabled(__CALLSITE.metadata(), interest)
-    };
-    if enabled {
-        (|value_set: $crate::field::ValueSet| {
-            let meta = __CALLSITE.metadata();
-            // event with contextual parent
-            $crate::Event::dispatch(
-                meta,
-                &value_set
-            );
-            $crate::__tracing_log!(
-                $lvl,
-                __CALLSITE,
-                &value_set
-            );
-        })($crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*));
-    } else {
-        $crate::__tracing_log!(
-            $lvl,
-            __CALLSITE,
-            &$crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*)
-        );
-    }
-});
-(name: $name:expr, target: $target:expr, $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        name: $name,
-        target: $target,
-        $lvl,
-        { message = $crate::__macro_support::format_args!($($arg)+), $($fields)* }
-    )
-);
-(name: $name:expr, target: $target:expr, $lvl:expr, $($k:ident).+ = $($fields:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $lvl, { $($k).+ = $($fields)* })
-);
-(name: $name:expr, target: $target:expr, $lvl:expr, $($arg:tt)+) => (
-    $crate::event!(name: $name, target: $target, $lvl, { $($arg)+ })
-);
-
-// Target / parent.
-(target: $target:expr, parent: $parent:expr, $lvl:expr, { $($fields:tt)* } )=> ({
-    use $crate::__macro_support::Callsite as _;
-    static __CALLSITE: $crate::callsite::DefaultCallsite = $crate::callsite2! {
-        name: $crate::__macro_support::concat!(
-            "event ",
-            $crate::__macro_support::file!(),
-            ":",
-            $crate::__macro_support::line!()
-        ),
-        kind: $crate::metadata::Kind::EVENT,
-        target: $target,
-        level: $lvl,
-        fields: $($fields)*
-    };
-
-    let enabled = $crate::level_enabled!($lvl) && {
-        let interest = __CALLSITE.interest();
-        !interest.is_never() && $crate::__macro_support::__is_enabled(__CALLSITE.metadata(), interest)
-    };
-    if enabled {
-        (|value_set: $crate::field::ValueSet| {
-            $crate::__tracing_log!(
-                $lvl,
-                __CALLSITE,
-                &value_set
-            );
-            let meta = __CALLSITE.metadata();
-            // event with explicit parent
-            $crate::Event::child_of(
-                $parent,
-                meta,
-                &value_set
-            );
-        })($crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*));
-    } else {
-        $crate::__tracing_log!(
-            $lvl,
-            __CALLSITE,
-            &$crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*)
-        );
-    }
-});
-(target: $target:expr, parent: $parent:expr, $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: $target,
-        parent: $parent,
-        $lvl,
-        { message = $crate::__macro_support::format_args!($($arg)+), $($fields)* }
-    )
-);
-(target: $target:expr, parent: $parent:expr, $lvl:expr, $($k:ident).+ = $($fields:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $lvl, { $($k).+ = $($fields)* })
-);
-(target: $target:expr, parent: $parent:expr, $lvl:expr, $($arg:tt)+) => (
-    $crate::event!(target: $target, parent: $parent, $lvl, { $($arg)+ })
-);
-
-// Name / parent.
-(name: $name:expr, parent: $parent:expr, $lvl:expr, { $($fields:tt)* } )=> ({
-    use $crate::__macro_support::Callsite as _;
-    static __CALLSITE: $crate::__macro_support::MacroCallsite = $crate::callsite2! {
-        name: $name,
-        kind: $crate::metadata::Kind::EVENT,
-        target: module_path!(),
-        level: $lvl,
-        fields: $($fields)*
-    };
-
-    let enabled = $crate::level_enabled!($lvl) && {
-        let interest = __CALLSITE.interest();
-        !interest.is_never() && __CALLSITE.is_enabled(interest)
-    };
-    if enabled {
-        (|value_set: $crate::field::ValueSet| {
-            $crate::__tracing_log!(
-                $lvl,
-                __CALLSITE,
-                &value_set
-            );
-            let meta = __CALLSITE.metadata();
-            // event with explicit parent
-            $crate::Event::child_of(
-                $parent,
-                meta,
-                &value_set
-            );
-        })($crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*));
-    } else {
-        $crate::__tracing_log!(
-            $lvl,
-            __CALLSITE,
-            &$crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*)
-        );
-    }
-});
-(name: $name:expr, parent: $parent:expr, $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        name: $name,
-        parent: $parent,
-        $lvl,
-        { message = $crate::__macro_support::format_args!($($arg)+), $($fields)* }
-    )
-);
-(name: $name:expr, parent: $parent:expr, $lvl:expr, $($k:ident).+ = $($fields:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $lvl, { $($k).+ = $($fields)* })
-);
-(name: $name:expr, parent: $parent:expr, $lvl:expr, $($arg:tt)+) => (
-    $crate::event!(name: $name, parent: $parent, $lvl, { $($arg)+ })
-);
-
-// Name.
-(name: $name:expr, $lvl:expr, { $($fields:tt)* } )=> ({
-    use $crate::__macro_support::Callsite as _;
-    static __CALLSITE: $crate::__macro_support::MacroCallsite = $crate::callsite2! {
-        name: $name,
-        kind: $crate::metadata::Kind::EVENT,
-        target: module_path!(),
-        level: $lvl,
-        fields: $($fields)*
-    };
-    let enabled = $crate::level_enabled!($lvl) && {
-        let interest = __CALLSITE.interest();
-        !interest.is_never() && $crate::__macro_support::__is_enabled(__CALLSITE.metadata(), interest)
-    };
-    if enabled {
-        (|value_set: $crate::field::ValueSet| {
-            let meta = __CALLSITE.metadata();
-            // event with contextual parent
-            $crate::Event::dispatch(
-                meta,
-                &value_set
-            );
-            $crate::__tracing_log!(
-                $lvl,
-                __CALLSITE,
-                &value_set
-            );
-        })($crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*));
-    } else {
-        $crate::__tracing_log!(
-            $lvl,
-            __CALLSITE,
-            &$crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*)
-        );
-    }
-});
-(name: $name:expr, $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        name: $name,
-        $lvl,
-        { message = $crate::__macro_support::format_args!($($arg)+), $($fields)* }
-    )
-);
-(name: $name:expr, $lvl:expr, $($k:ident).+ = $($fields:tt)* ) => (
-    $crate::event!(name: $name, $lvl, { $($k).+ = $($fields)* })
-);
-(name: $name:expr, $lvl:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, $lvl, { $($arg)+ })
-);
-
-// Target.
-(target: $target:expr, $lvl:expr, { $($fields:tt)* } )=> ({
-    use $crate::__macro_support::Callsite as _;
-    static __CALLSITE: $crate::callsite::DefaultCallsite = $crate::callsite2! {
-        name: $crate::__macro_support::concat!(
-            "event ",
-            $crate::__macro_support::file!(),
-            ":",
-            $crate::__macro_support::line!()
-        ),
-        kind: $crate::metadata::Kind::EVENT,
-        target: $target,
-        level: $lvl,
-        fields: $($fields)*
-    };
-    let enabled = $crate::level_enabled!($lvl) && {
-        let interest = __CALLSITE.interest();
-        !interest.is_never() && $crate::__macro_support::__is_enabled(__CALLSITE.metadata(), interest)
-    };
-    if enabled {
-        (|value_set: $crate::field::ValueSet| {
-            let meta = __CALLSITE.metadata();
-            // event with contextual parent
-            $crate::Event::dispatch(
-                meta,
-                &value_set
-            );
-            $crate::__tracing_log!(
-                $lvl,
-                __CALLSITE,
-                &value_set
-            );
-        })($crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*));
-    } else {
-        $crate::__tracing_log!(
-            $lvl,
-            __CALLSITE,
-            &$crate::valueset!(__CALLSITE.metadata().fields(), $($fields)*)
-        );
-    }
-});
-(target: $target:expr, $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: $target,
-        $lvl,
-        { message = $crate::__macro_support::format_args!($($arg)+), $($fields)* }
-    )
-);
-(target: $target:expr, $lvl:expr, $($k:ident).+ = $($fields:tt)* ) => (
-    $crate::event!(target: $target, $lvl, { $($k).+ = $($fields)* })
-);
-(target: $target:expr, $lvl:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, $lvl, { $($arg)+ })
-);
-
-// Parent.
-(parent: $parent:expr, $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        { message = $crate::__macro_support::format_args!($($arg)+), $($fields)* }
-    )
-);
-(parent: $parent:expr, $lvl:expr, $($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        { $($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, $lvl:expr, ?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, $lvl:expr, %$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        { %$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, $lvl:expr, $($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        { $($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, $lvl:expr, %$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        { %$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, $lvl:expr, ?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $lvl,
-        { ?$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, $lvl:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: module_path!(), parent: $parent, $lvl, { $($arg)+ })
-);
-
-// ...
-( $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        $lvl,
-        { message = $crate::__macro_support::format_args!($($arg)+), $($fields)* }
-    )
-);
-( $lvl:expr, { $($fields:tt)* }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        $lvl,
-        { message = format_args!($($arg)+), $($fields)* }
-    )
-);
-($lvl:expr, $($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $lvl,
-        { $($k).+ = $($field)*}
-    )
-);
-($lvl:expr, $($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $lvl,
-        { $($k).+, $($field)*}
-    )
-);
-($lvl:expr, ?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $lvl,
-        { ?$($k).+, $($field)*}
-    )
-);
-($lvl:expr, %$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $lvl,
-        { %$($k).+, $($field)*}
-    )
-);
-($lvl:expr, ?$($k:ident).+) => (
-    $crate::event!($lvl, ?$($k).+,)
-);
-($lvl:expr, %$($k:ident).+) => (
-    $crate::event!($lvl, %$($k).+,)
-);
-($lvl:expr, $($k:ident).+) => (
-    $crate::event!($lvl, $($k).+,)
-);
-( $lvl:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: module_path!(), $lvl, { $($arg)+ })
-);
-}
-
-#[macro_export]
-macro_rules! event_enabled {
-($($rest:tt)*)=> (
-    $crate::enabled!(kind: $crate::metadata::Kind::EVENT, $($rest)*)
-)
-}
-
-#[macro_export]
-macro_rules! span_enabled {
-($($rest:tt)*)=> (
-    $crate::enabled!(kind: $crate::metadata::Kind::SPAN, $($rest)*)
-)
-}
-
-#[macro_export]
-macro_rules! enabled {
-(kind: $kind:expr, target: $target:expr, $lvl:expr, { $($fields:tt)* } )=> ({
-    if $crate::level_enabled!($lvl) {
-        use $crate::__macro_support::Callsite as _;
-        static __CALLSITE: $crate::callsite::DefaultCallsite = $crate::callsite2! {
-            name: $crate::__macro_support::concat!(
-                "enabled ",
-                $crate::__macro_support::file!(),
-                ":",
-                $crate::__macro_support::line!()
-            ),
-            kind: $kind.hint(),
-            target: $target,
-            level: $lvl,
-            fields: $($fields)*
-        };
-        let interest = __CALLSITE.interest();
-        if !interest.is_never() && $crate::__macro_support::__is_enabled(__CALLSITE.metadata(), interest) {
-            let meta = __CALLSITE.metadata();
-            $crate::dispatcher::get_default(|current| current.enabled(meta))
-        } else {
-            false
-        }
-    } else {
-        false
-    }
-});
-// Just target and level
-(kind: $kind:expr, target: $target:expr, $lvl:expr ) => (
-    $crate::enabled!(kind: $kind, target: $target, $lvl, { })
-);
-(target: $target:expr, $lvl:expr ) => (
-    $crate::enabled!(kind: $crate::metadata::Kind::HINT, target: $target, $lvl, { })
-);
-
-// These four cases handle fields with no values
-(kind: $kind:expr, target: $target:expr, $lvl:expr, $($field:tt)*) => (
-    $crate::enabled!(
-        kind: $kind,
-        target: $target,
-        $lvl,
-        { $($field)*}
-    )
-);
-(target: $target:expr, $lvl:expr, $($field:tt)*) => (
-    $crate::enabled!(
-        kind: $crate::metadata::Kind::HINT,
-        target: $target,
-        $lvl,
-        { $($field)*}
-    )
-);
-
-// Level and field case
-(kind: $kind:expr, $lvl:expr, $($field:tt)*) => (
-    $crate::enabled!(
-        kind: $kind,
-        target: module_path!(),
-        $lvl,
-        { $($field)*}
-    )
-);
-
-// Simplest `enabled!` case
-(kind: $kind:expr, $lvl:expr) => (
-    $crate::enabled!(kind: $kind, target: module_path!(), $lvl, { })
-);
-($lvl:expr) => (
-    $crate::enabled!(kind: $crate::metadata::Kind::HINT, target: module_path!(), $lvl, { })
-);
-
-// Fallthrough from above
-($lvl:expr, $($field:tt)*) => (
-    $crate::enabled!(
-        kind: $crate::metadata::Kind::HINT,
-        target: module_path!(),
-        $lvl,
-        { $($field)*}
-    )
-);
-}
-
-#[macro_export]
-macro_rules! trace {
-// Name / target / parent.
-(name: $name:expr, target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::TRACE, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::TRACE, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::TRACE, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::TRACE, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::TRACE, {}, $($arg)+)
-);
-
-// Name / target.
-(name: $name:expr, target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::TRACE, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::TRACE, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::TRACE, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::TRACE, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::TRACE, {}, $($arg)+)
-);
-
-// Target / parent.
-(target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::TRACE, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::TRACE, { $($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::TRACE, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::TRACE, { %$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::TRACE, {}, $($arg)+)
-);
-
-// Name / parent.
-(name: $name:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::TRACE, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::TRACE, { $($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::TRACE, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::TRACE, { %$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::TRACE, {}, $($arg)+)
-);
-
-// Name.
-(name: $name:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::TRACE, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::TRACE, { $($k).+ $($field)* })
-);
-(name: $name:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::TRACE, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::TRACE, { %$($k).+ $($field)* })
-);
-(name: $name:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, $crate::Level::TRACE, {}, $($arg)+)
-);
-
-// Target.
-(target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::TRACE, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::TRACE, { $($k).+ $($field)* })
-);
-(target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::TRACE, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::TRACE, { %$($k).+ $($field)* })
-);
-(target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, $crate::Level::TRACE, {}, $($arg)+)
-);
-
-// Parent.
-(parent: $parent:expr, { $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-(parent: $parent:expr, $($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        { $($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        { %$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, $($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        { $($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        { ?$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        { %$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, $($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::TRACE,
-        {},
-        $($arg)+
-    )
-);
-
-// ...
-({ $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-($($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { $($k).+ = $($field)*}
-    )
-);
-(?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(%$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { %$($k).+ = $($field)*}
-    )
-);
-($($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { $($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { ?$($k).+, $($field)*}
-    )
-);
-(%$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { %$($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { ?$($k).+ }
-    )
-);
-(%$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { %$($k).+ }
-    )
-);
-($($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        { $($k).+ }
-    )
-);
-($($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::TRACE,
-        $($arg)+
-    )
-);
-}
-
-#[macro_export]
-macro_rules! debug {
-// Name / target / parent.
-(name: $name:expr, target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::DEBUG, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::DEBUG, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::DEBUG, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::DEBUG, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::DEBUG, {}, $($arg)+)
-);
-
-// Name / target.
-(name: $name:expr, target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::DEBUG, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::DEBUG, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::DEBUG, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::DEBUG, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::DEBUG, {}, $($arg)+)
-);
-
-// Target / parent.
-(target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::DEBUG, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::DEBUG, { $($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::DEBUG, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::DEBUG, { %$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::DEBUG, {}, $($arg)+)
-);
-
-// Name / parent.
-(name: $name:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::DEBUG, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::DEBUG, { $($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::DEBUG, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::DEBUG, { %$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::DEBUG, {}, $($arg)+)
-);
-
-// Name.
-(name: $name:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::DEBUG, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::DEBUG, { $($k).+ $($field)* })
-);
-(name: $name:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::DEBUG, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::DEBUG, { %$($k).+ $($field)* })
-);
-(name: $name:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, $crate::Level::DEBUG, {}, $($arg)+)
-);
-
-// Target.
-(target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::DEBUG, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::DEBUG, { $($k).+ $($field)* })
-);
-(target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::DEBUG, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::DEBUG, { %$($k).+ $($field)* })
-);
-(target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, $crate::Level::DEBUG, {}, $($arg)+)
-);
-
-// Parent.
-(parent: $parent:expr, { $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-(parent: $parent:expr, $($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        { $($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        { %$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, $($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        { $($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        { ?$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        { %$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, $($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::DEBUG,
-        {},
-        $($arg)+
-    )
-);
-
-// ...
-({ $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-($($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { $($k).+ = $($field)*}
-    )
-);
-(?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(%$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { %$($k).+ = $($field)*}
-    )
-);
-($($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { $($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { ?$($k).+, $($field)*}
-    )
-);
-(%$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { %$($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { ?$($k).+ }
-    )
-);
-(%$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { %$($k).+ }
-    )
-);
-($($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        { $($k).+ }
-    )
-);
-($($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::DEBUG,
-        $($arg)+
-    )
-);
-}
-
-#[macro_export]
-macro_rules! info {
-// Name / target / parent.
-(name: $name:expr, target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::INFO, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::INFO, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::INFO, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::INFO, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::INFO, {}, $($arg)+)
-);
-
-// Name / target.
-(name: $name:expr, target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::INFO, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::INFO, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::INFO, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::INFO, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::INFO, {}, $($arg)+)
-);
-
-// Target / parent.
-(target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::INFO, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::INFO, { $($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::INFO, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::INFO, { %$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::INFO, {}, $($arg)+)
-);
-
-// Name / parent.
-(name: $name:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::INFO, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::INFO, { $($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::INFO, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::INFO, { %$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::INFO, {}, $($arg)+)
-);
-
-// Name.
-(name: $name:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::INFO, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::INFO, { $($k).+ $($field)* })
-);
-(name: $name:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::INFO, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::INFO, { %$($k).+ $($field)* })
-);
-(name: $name:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, $crate::Level::INFO, {}, $($arg)+)
-);
-
-// Target.
-(target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::INFO, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::INFO, { $($k).+ $($field)* })
-);
-(target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::INFO, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::INFO, { %$($k).+ $($field)* })
-);
-(target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, $crate::Level::INFO, {}, $($arg)+)
-);
-
-// Parent.
-(parent: $parent:expr, { $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-(parent: $parent:expr, $($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        { $($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        { %$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, $($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        { $($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        { ?$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        { %$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, $($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::INFO,
-        {},
-        $($arg)+
-    )
-);
-
-// ...
-({ $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-($($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { $($k).+ = $($field)*}
-    )
-);
-(?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(%$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { %$($k).+ = $($field)*}
-    )
-);
-($($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { $($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { ?$($k).+, $($field)*}
-    )
-);
-(%$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { %$($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { ?$($k).+ }
-    )
-);
-(%$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { %$($k).+ }
-    )
-);
-($($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        { $($k).+ }
-    )
-);
-($($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::INFO,
-        $($arg)+
-    )
-);
-}
-
-#[macro_export]
-macro_rules! warn {
-// Name / target / parent.
-(name: $name:expr, target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::WARN, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::WARN, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::WARN, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::WARN, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::WARN, {}, $($arg)+)
-);
-
-// Name / target.
-(name: $name:expr, target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::WARN, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::WARN, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::WARN, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::WARN, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::WARN, {}, $($arg)+)
-);
-
-// Target / parent.
-(target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::WARN, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::WARN, { $($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::WARN, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::WARN, { %$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::WARN, {}, $($arg)+)
-);
-
-// Name / parent.
-(name: $name:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::WARN, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::WARN, { $($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::WARN, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::WARN, { %$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::WARN, {}, $($arg)+)
-);
-
-// Name.
-(name: $name:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::WARN, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::WARN, { $($k).+ $($field)* })
-);
-(name: $name:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::WARN, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::WARN, { %$($k).+ $($field)* })
-);
-(name: $name:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, $crate::Level::WARN, {}, $($arg)+)
-);
-
-// Target.
-(target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::WARN, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::WARN, { $($k).+ $($field)* })
-);
-(target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::WARN, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::WARN, { %$($k).+ $($field)* })
-);
-(target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, $crate::Level::WARN, {}, $($arg)+)
-);
-
-// Parent.
-(parent: $parent:expr, { $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-(parent: $parent:expr, $($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        { $($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        { %$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, $($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        { $($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        { ?$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        { %$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, $($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::WARN,
-        {},
-        $($arg)+
-    )
-);
-
-// ...
-({ $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-($($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { $($k).+ = $($field)*}
-    )
-);
-(?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(%$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { %$($k).+ = $($field)*}
-    )
-);
-($($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { $($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { ?$($k).+, $($field)*}
-    )
-);
-(%$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { %$($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { ?$($k).+ }
-    )
-);
-(%$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { %$($k).+ }
-    )
-);
-($($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        { $($k).+ }
-    )
-);
-($($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::WARN,
-        $($arg)+
-    )
-);
-}
-
-#[macro_export]
-macro_rules! error {
-// Name / target / parent.
-(name: $name:expr, target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::ERROR, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::ERROR, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::ERROR, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::ERROR, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, parent: $parent, $crate::Level::ERROR, {}, $($arg)+)
-);
-
-// Name / target.
-(name: $name:expr, target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::ERROR, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::ERROR, { $($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::ERROR, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::ERROR, { %$($k).+ $($field)* })
-);
-(name: $name:expr, target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, target: $target, $crate::Level::ERROR, {}, $($arg)+)
-);
-
-// Target / parent.
-(target: $target:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::ERROR, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::ERROR, { $($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::ERROR, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::ERROR, { %$($k).+ $($field)* })
-);
-(target: $target:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, parent: $parent, $crate::Level::ERROR, {}, $($arg)+)
-);
-
-// Name / parent.
-(name: $name:expr, parent: $parent:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::ERROR, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, parent: $parent:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::ERROR, { $($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::ERROR, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::ERROR, { %$($k).+ $($field)* })
-);
-(name: $name:expr, parent: $parent:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, parent: $parent, $crate::Level::ERROR, {}, $($arg)+)
-);
-
-// Name.
-(name: $name:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::ERROR, { $($field)* }, $($arg)*)
-);
-(name: $name:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::ERROR, { $($k).+ $($field)* })
-);
-(name: $name:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::ERROR, { ?$($k).+ $($field)* })
-);
-(name: $name:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(name: $name, $crate::Level::ERROR, { %$($k).+ $($field)* })
-);
-(name: $name:expr, $($arg:tt)+ ) => (
-    $crate::event!(name: $name, $crate::Level::ERROR, {}, $($arg)+)
-);
-
-// Target.
-(target: $target:expr, { $($field:tt)* }, $($arg:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::ERROR, { $($field)* }, $($arg)*)
-);
-(target: $target:expr, $($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::ERROR, { $($k).+ $($field)* })
-);
-(target: $target:expr, ?$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::ERROR, { ?$($k).+ $($field)* })
-);
-(target: $target:expr, %$($k:ident).+ $($field:tt)* ) => (
-    $crate::event!(target: $target, $crate::Level::ERROR, { %$($k).+ $($field)* })
-);
-(target: $target:expr, $($arg:tt)+ ) => (
-    $crate::event!(target: $target, $crate::Level::ERROR, {}, $($arg)+)
-);
-
-// Parent.
-(parent: $parent:expr, { $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-(parent: $parent:expr, $($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        { $($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        { %$($k).+ = $($field)*}
-    )
-);
-(parent: $parent:expr, $($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        { $($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, ?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        { ?$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, %$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        { %$($k).+, $($field)*}
-    )
-);
-(parent: $parent:expr, $($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        parent: $parent,
-        $crate::Level::ERROR,
-        {},
-        $($arg)+
-    )
-);
-
-// ...
-({ $($field:tt)+ }, $($arg:tt)+ ) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { $($field)+ },
-        $($arg)+
-    )
-);
-($($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { $($k).+ = $($field)*}
-    )
-);
-(?$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { ?$($k).+ = $($field)*}
-    )
-);
-(%$($k:ident).+ = $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { %$($k).+ = $($field)*}
-    )
-);
-($($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { $($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { ?$($k).+, $($field)*}
-    )
-);
-(%$($k:ident).+, $($field:tt)*) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { %$($k).+, $($field)*}
-    )
-);
-(?$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { ?$($k).+ }
-    )
-);
-(%$($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { %$($k).+ }
-    )
-);
-($($k:ident).+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        { $($k).+ }
-    )
-);
-($($arg:tt)+) => (
-    $crate::event!(
-        target: module_path!(),
-        $crate::Level::ERROR,
-        $($arg)+
-    )
-);
-}
-
-#[doc(hidden)]
-#[macro_export]
-macro_rules! callsite {
-(name: $name:expr, kind: $kind:expr, fields: $($fields:tt)*) => {{
-    $crate::callsite! {
-        name: $name,
-        kind: $kind,
-        target: module_path!(),
-        level: $crate::Level::TRACE,
-        fields: $($fields)*
-    }
-}};
-(
-    name: $name:expr,
-    kind: $kind:expr,
-    level: $lvl:expr,
-    fields: $($fields:tt)*
-) => {{
-    $crate::callsite! {
-        name: $name,
-        kind: $kind,
-        target: module_path!(),
-        level: $lvl,
-        fields: $($fields)*
-    }
-}};
-(
-    name: $name:expr,
-    kind: $kind:expr,
-    target: $target:expr,
-    level: $lvl:expr,
-    fields: $($fields:tt)*
-) => {{
-    static META: $crate::Metadata<'static> = {
-        $crate::metadata! {
-            name: $name,
-            target: $target,
-            level: $lvl,
-            fields: $crate::fieldset!( $($fields)* ),
-            callsite: &__CALLSITE,
-            kind: $kind,
-        }
-    };
-    static __CALLSITE: $crate::callsite::DefaultCallsite = $crate::callsite::DefaultCallsite::new(&META);
-    __CALLSITE.register();
-    &__CALLSITE
-}};
-}
-
-#[doc(hidden)]
-#[macro_export]
-macro_rules! callsite2 {
-(name: $name:expr, kind: $kind:expr, fields: $($fields:tt)*) => {{
-    $crate::callsite2! {
-        name: $name,
-        kind: $kind,
-        target: module_path!(),
-        level: $crate::Level::TRACE,
-        fields: $($fields)*
-    }
-}};
-(
-    name: $name:expr,
-    kind: $kind:expr,
-    level: $lvl:expr,
-    fields: $($fields:tt)*
-) => {{
-    $crate::callsite2! {
-        name: $name,
-        kind: $kind,
-        target: module_path!(),
-        level: $lvl,
-        fields: $($fields)*
-    }
-}};
-(
-    name: $name:expr,
-    kind: $kind:expr,
-    target: $target:expr,
-    level: $lvl:expr,
-    fields: $($fields:tt)*
-) => {{
-    static META: $crate::Metadata<'static> = {
-        $crate::metadata! {
-            name: $name,
-            target: $target,
-            level: $lvl,
-            fields: $crate::fieldset!( $($fields)* ),
-            callsite: &__CALLSITE,
-            kind: $kind,
-        }
-    };
-    $crate::callsite::DefaultCallsite::new(&META)
-}};
-}
-
-#[macro_export]
-#[doc(hidden)]
-macro_rules! level_enabled {
-($lvl:expr) => {
-    $lvl <= $crate::level_filters::STATIC_MAX_LEVEL
-        && $lvl <= $crate::level_filters::LevelFilter::current()
-};
-}
-
-#[doc(hidden)]
-#[macro_export]
-macro_rules! valueset {
-
-// === base case ===
-(@ { $(,)* $($val:expr),* $(,)* }, $next:expr $(,)*) => {
-    &[ $($val),* ]
-};
-
-(@ { $(,)* $($out:expr),* }, $next:expr, $($k:ident).+ = ?$val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&debug(&$val) as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $($k:ident).+ = %$val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&display(&$val) as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $($k:ident).+ = $val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&$val as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $($k:ident).+, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&$($k).+ as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, ?$($k:ident).+, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&debug(&$($k).+) as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, %$($k:ident).+, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&display(&$($k).+) as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $($k:ident).+ = ?$val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&debug(&$val) as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $($k:ident).+ = %$val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&display(&$val) as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $($k:ident).+ = $val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&$val as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $($k:ident).+) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&$($k).+ as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, ?$($k:ident).+) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&debug(&$($k).+) as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, %$($k:ident).+) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&display(&$($k).+) as &dyn Value)) },
-        $next,
-    )
-};
-
-// Handle literal names
-(@ { $(,)* $($out:expr),* }, $next:expr, $k:literal = ?$val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&debug(&$val) as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $k:literal = %$val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&display(&$val) as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $k:literal = $val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&$val as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $k:literal = ?$val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&debug(&$val) as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $k:literal = %$val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&display(&$val) as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, $k:literal = $val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, $crate::__macro_support::Option::Some(&$val as &dyn Value)) },
-        $next,
-    )
-};
-
-// Handle constant names
-(@ { $(,)* $($out:expr),* }, $next:expr, { $k:expr } = ?$val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, Some(&debug(&$val) as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, { $k:expr } = %$val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, Some(&display(&$val) as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, { $k:expr } = $val:expr, $($rest:tt)*) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, Some(&$val as &dyn Value)) },
-        $next,
-        $($rest)*
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, { $k:expr } = ?$val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, Some(&debug(&$val) as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, { $k:expr } = %$val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, Some(&display(&$val) as &dyn Value)) },
-        $next,
-    )
-};
-(@ { $(,)* $($out:expr),* }, $next:expr, { $k:expr } = $val:expr) => {
-    $crate::valueset!(
-        @ { $($out),*, (&$next, Some(&$val as &dyn Value)) },
-        $next,
-    )
-};
-
-(@ { $(,)* $($out:expr),* }, $next:expr, $($rest:tt)+) => {
-    $crate::valueset!(@ { (&$next, $crate::__macro_support::Option::Some(&$crate::__macro_support::format_args!($($rest)+) as &dyn Value)), $($out),* }, $next, )
-};
-
-($fields:expr, $($kvs:tt)+) => {
-    {
-        #[allow(unused_imports)]
-        use $crate::field::{debug, display, Value};
-        let mut iter = $fields.iter();
-        $fields.value_set($crate::valueset!(
-            @ { },
-            $crate::__macro_support::Iterator::next(&mut iter).expect("FieldSet corrupted (this is a bug)"),
-            $($kvs)+
-        ))
-    }
-};
-($fields:expr,) => {
-    {
-        $fields.value_set(&[])
-    }
-};
-}
-
-#[doc(hidden)]
-#[macro_export]
-macro_rules! fieldset {
-(@ { $(,)* $($out:expr),* $(,)* } $(,)*) => {
-    &[ $($out),* ]
-};
-
-(@ { $(,)* $($out:expr),* } $($k:ident).+ = ?$val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $crate::__tracing_stringify!($($k).+) } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } $($k:ident).+ = %$val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $crate::__tracing_stringify!($($k).+) } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } $($k:ident).+ = $val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $crate::__tracing_stringify!($($k).+) } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } ?$($k:ident).+, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $crate::__tracing_stringify!($($k).+) } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } %$($k:ident).+, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $crate::__tracing_stringify!($($k).+) } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } $($k:ident).+, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $crate::__tracing_stringify!($($k).+) } $($rest)*)
-};
-
-// Handle literal names
-(@ { $(,)* $($out:expr),* } $k:literal = ?$val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $k } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } $k:literal = %$val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $k } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } $k:literal = $val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $k } $($rest)*)
-};
-
-// Handle constant names
-(@ { $(,)* $($out:expr),* } { $k:expr } = ?$val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $k } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } { $k:expr } = %$val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $k } $($rest)*)
-};
-(@ { $(,)* $($out:expr),* } { $k:expr } = $val:expr, $($rest:tt)*) => {
-    $crate::fieldset!(@ { $($out),*, $k } $($rest)*)
-};
-
-(@ { $(,)* $($out:expr),* } $($rest:tt)+) => {
-    $crate::fieldset!(@ { "message", $($out),*, })
-};
-
-($($args:tt)*) => {
-    $crate::fieldset!(@ { } $($args)*,)
-};
-
-}
-
-#[cfg(feature = "log")]
-#[doc(hidden)]
-#[macro_export]
-macro_rules! level_to_log {
-($level:expr) => {
-    match $level {
-        $crate::Level::ERROR => $crate::log::Level::Error,
-        $crate::Level::WARN => $crate::log::Level::Warn,
-        $crate::Level::INFO => $crate::log::Level::Info,
-        $crate::Level::DEBUG => $crate::log::Level::Debug,
-        _ => $crate::log::Level::Trace,
-    }
-};
-}
-
-#[doc(hidden)]
-#[macro_export]
-macro_rules! __tracing_stringify {
-($($t:tt)*) => {
-    stringify!($($t)*)
-};
-}
-
-#[cfg(not(feature = "log"))]
-#[doc(hidden)]
-#[macro_export]
-macro_rules! __tracing_log {
-($level:expr, $callsite:expr, $value_set:expr) => {};
-}
-
-#[cfg(feature = "log")]
-#[doc(hidden)]
-#[macro_export]
-macro_rules! __tracing_log {
-($level:expr, $callsite:expr, $value_set:expr) => {
-    $crate::if_log_enabled! { $level, {
-        use $crate::log;
-        let level = $crate::level_to_log!($level);
-        if level <= log::max_level() {
-            let meta = $callsite.metadata();
-            let log_meta = log::Metadata::builder()
-                .level(level)
-                .target(meta.target())
-                .build();
-            let logger = log::logger();
-            if logger.enabled(&log_meta) {
-                $crate::__macro_support::__tracing_log(meta, logger, log_meta, $value_set)
-            }
-        }
-    }}
-};
-}
-
-#[cfg(not(feature = "log"))]
-#[doc(hidden)]
-#[macro_export]
-macro_rules! if_log_enabled {
-($lvl:expr, $e:expr;) => {
-    $crate::if_log_enabled! { $lvl, $e }
-};
-($lvl:expr, $if_log:block) => {
-    $crate::if_log_enabled! { $lvl, $if_log else {} }
-};
-($lvl:expr, $if_log:block else $else_block:block) => {
-    $else_block
-};
-}
-
-#[cfg(all(feature = "log", not(feature = "log-always")))]
-#[doc(hidden)]
-#[macro_export]
-macro_rules! if_log_enabled {
-($lvl:expr, $e:expr;) => {
-    $crate::if_log_enabled! { $lvl, $e }
-};
-($lvl:expr, $if_log:block) => {
-    $crate::if_log_enabled! { $lvl, $if_log else {} }
-};
-($lvl:expr, $if_log:block else $else_block:block) => {
-    if $crate::level_to_log!($lvl) <= $crate::log::STATIC_MAX_LEVEL {
-        if !$crate::dispatcher::has_been_set() {
-            $if_log
-        } else {
-            $else_block
-        }
-    } else {
-        $else_block
-    }
-};
-}
-
-#[cfg(all(feature = "log", feature = "log-always"))]
-#[doc(hidden)]
-#[macro_export]
-macro_rules! if_log_enabled {
-($lvl:expr, $e:expr;) => {
-    $crate::if_log_enabled! { $lvl, $e }
-};
-($lvl:expr, $if_log:block) => {
-    $crate::if_log_enabled! { $lvl, $if_log else {} }
-};
-($lvl:expr, $if_log:block else $else_block:block) => {
-    if $crate::level_to_log!($lvl) <= $crate::log::STATIC_MAX_LEVEL {
-        #[allow(unused_braces)]
-        $if_log
-    } else {
-        $else_block
-    }
-};
-}
-
-//- /lib.rs crate:ra_test_fixture deps:tracing
-fn foo() {
-tracing::error!();
-}
-    "#,
-        &["E0432", "inactive-code", "unresolved-macro-call", "syntax-error", "macro-error"],
-    );
-}
diff --git a/crates/project-model/src/tests.rs b/crates/project-model/src/tests.rs
index 681bce3a5a..f111383112 100644
--- a/crates/project-model/src/tests.rs
+++ b/crates/project-model/src/tests.rs
@@ -49,6 +49,7 @@ fn load_workspace_from_metadata(file: &str) -> ProjectWorkspace {
         rustc_cfg: Vec::new(),
         toolchain: None,
         target_layout: Err("target_data_layout not loaded".into()),
+        extra_includes: Vec::new(),
     }
 }
 
@@ -63,6 +64,7 @@ fn load_rust_project(file: &str) -> (CrateGraph, ProcMacroPaths) {
         toolchain: None,
         target_layout: Err(Arc::from("test has no data layout")),
         cfg_overrides: Default::default(),
+        extra_includes: Vec::new(),
     };
     to_crate_graph(project_workspace, &mut Default::default())
 }
@@ -284,6 +286,7 @@ fn smoke_test_real_sysroot_cargo() {
         cfg_overrides: Default::default(),
         toolchain: None,
         target_layout: Err("target_data_layout not loaded".into()),
+        extra_includes: Vec::new(),
     };
     project_workspace.to_crate_graph(
         &mut {
diff --git a/crates/rust-analyzer/src/cli/rustc_tests.rs b/crates/rust-analyzer/src/cli/rustc_tests.rs
index 6b0ce4db7c..199f61e70f 100644
--- a/crates/rust-analyzer/src/cli/rustc_tests.rs
+++ b/crates/rust-analyzer/src/cli/rustc_tests.rs
@@ -93,6 +93,7 @@ impl Tester {
             toolchain: None,
             target_layout: data_layout.map(Arc::from).map_err(|it| Arc::from(it.to_string())),
             cfg_overrides: Default::default(),
+            extra_includes: vec![],
         };
         let load_cargo_config = LoadCargoConfig {
             load_out_dirs_from_check: false,
diff --git a/crates/test-fixture/Cargo.toml b/crates/test-fixture/Cargo.toml
index 95f4cb9d67..c860e7b118 100644
--- a/crates/test-fixture/Cargo.toml
+++ b/crates/test-fixture/Cargo.toml
@@ -2,8 +2,6 @@
 name = "test-fixture"
 version = "0.0.0"
 rust-version.workspace = true
-description = "Test fixtures for rust-analyzer."
-
 edition.workspace = true
 license.workspace = true
 authors.workspace = true