rust/compiler/rustc_builtin_macros/src
Jacob Pratt 25b81bf5ad
Rollup merge of #145590 - nnethercote:ModKind-Inline, r=petrochenkov
Prevent impossible combinations in `ast::ModKind`.

`ModKind::Loaded` has an `inline` field and a `had_parse_error` field. If the `inline` field is `Inline::Yes` then `had_parse_error` must be `Ok(())`.

This commit moves the `had_parse_error` field into the `Inline::No` variant. This makes it impossible to create the nonsensical combination of `inline == Inline::Yes` and `had_parse_error = Err(_)`.

r? ```@Urgau```
2025-08-21 01:12:19 -04:00
..
assert remove P 2025-08-09 15:47:01 +08:00
deriving Avoid using () in derive(From) output. 2025-08-19 18:16:57 +10:00
format_foreign Rustfmt 2025-02-08 22:12:13 +00:00
alloc_error_handler.rs remove P 2025-08-09 15:47:01 +08:00
asm.rs remove P 2025-08-09 15:47:01 +08:00
assert.rs Change the desugaring of assert! for better error output 2025-08-12 16:30:48 +00:00
autodiff.rs Remove inlining for autodiff handling 2025-08-14 16:30:16 +00:00
cfg.rs Speed up Parser::expected_token_types. 2024-12-19 16:05:41 +11:00
cfg_accessible.rs Allow attr entries to declare list of alternatives for List and NamedValueStr 2025-08-11 16:00:49 +00:00
cfg_eval.rs remove P 2025-08-09 15:47:01 +08:00
cfg_select.rs update cfg_select! documentation 2025-07-14 22:29:28 +02:00
cmdline_attrs.rs Improve -Z crate-attr diagnostics 2025-04-13 16:46:02 -04:00
compile_error.rs Reformat use declarations. 2024-07-29 08:26:52 +10:00
concat.rs Re-export more rustc_span::symbol things from rustc_span. 2024-12-18 13:38:53 +11:00
concat_bytes.rs remove P 2025-08-09 15:47:01 +08:00
contracts.rs Fix imports, remove attrs for unused_* 2025-02-10 20:15:30 +00:00
define_opaque.rs Test define opaques in extern items 2025-03-25 16:44:59 +00:00
derive.rs Allow attr entries to declare list of alternatives for List and NamedValueStr 2025-08-11 16:00:49 +00:00
edition_panic.rs remove P 2025-08-09 15:47:01 +08:00
env.rs Remove AstDeref. 2025-05-10 08:58:47 +10:00
errors.rs Implement #[derive(From)] 2025-08-15 12:07:15 +02:00
format.rs remove P 2025-08-09 15:47:01 +08:00
format_foreign.rs remove P 2025-08-09 15:47:01 +08:00
global_allocator.rs remove P 2025-08-09 15:47:01 +08:00
iter.rs remove P 2025-08-09 15:47:01 +08:00
lib.rs Rollup merge of #145429 - bjorn3:codegen_fn_attrs_improvements, r=jdonszelmann 2025-08-19 19:45:31 +08:00
log_syntax.rs Adjust some pubs. 2024-04-26 13:29:20 +10:00
pattern_type.rs remove P 2025-08-09 15:47:01 +08:00
proc_macro_harness.rs Remove the old target checking logic 2025-08-14 18:18:42 +02:00
source_util.rs remove P 2025-08-09 15:47:01 +08:00
standard_library_imports.rs expand: Micro-optimize prelude injection 2025-07-28 17:35:09 +03:00
test.rs remove P 2025-08-09 15:47:01 +08:00
test_harness.rs Prevent impossible combinations in ast::ModKind. 2025-08-19 21:57:31 +10:00
trace_macros.rs Rollup merge of #134161 - nnethercote:overhaul-token-cursors, r=spastorino 2024-12-18 22:56:53 +08:00
util.rs remove P 2025-08-09 15:47:01 +08:00