rust/compiler/rustc_mir_transform/src
Jacob Pratt 70b69a2384
Rollup merge of #126721 - Zalathar:nested-cov-attr, r=oli-obk
coverage: Make `#[coverage(..)]` apply recursively to nested functions

This PR makes the (currently-unstable) `#[coverage(off)]` and `#[coverage(on)]` attributes apply recursively to all nested functions/closures, instead of just the function they are directly attached to.

Those attributes can now also be applied to modules and to impl/impl-trait blocks, where they have no direct effect, but will be inherited by all enclosed functions/closures/methods that don't override the inherited value.

---

Fixes #126625.
2024-06-27 02:06:18 -04:00
..
coroutine Rename InstanceDef -> InstanceKind 2024-06-16 21:35:21 -04:00
coverage coverage: Apply #[coverage(..)] recursively to nested functions 2024-06-26 10:08:05 +10:00
inline Rename InstanceDef -> InstanceKind 2024-06-16 21:35:21 -04:00
shim Rename InstanceDef -> InstanceKind 2024-06-16 21:35:21 -04:00
abort_unwinding_calls.rs Remove extern crate rustc_middle from rustc_mir_transform. 2024-05-13 08:20:18 +10:00
add_call_guards.rs remove redundant imports 2023-12-10 10:56:22 +08:00
add_moves_for_packed_drops.rs remove redundant imports 2023-12-10 10:56:22 +08:00
add_retag.rs Use is_lang_item more aggressively 2024-06-14 16:54:29 -04:00
add_subtyping_projections.rs remove redundant imports 2023-12-10 10:56:22 +08:00
check_alignment.rs Make builtin_deref just return a Ty 2024-05-09 22:55:00 -04:00
check_const_item_mutation.rs Rename TyCtxt::emit_spanned_lint as TyCtxt::emit_node_span_lint. 2024-01-23 08:09:05 +11:00
check_packed_ref.rs Remove extern crate rustc_middle from rustc_mir_transform. 2024-05-13 08:20:18 +10:00
cleanup_post_borrowck.rs Ban ArrayToPointer and MutToConstPointer from runtime MIR 2024-06-19 10:44:01 -07:00
copy_prop.rs Merge borrowed locals too. 2024-04-20 19:20:38 +00:00
coroutine.rs Save 2 pointers in TerminatorKind (96 → 80 bytes) 2024-06-21 18:02:05 -07:00
cost_checker.rs Make MIR inlining costs in build-std independent of config.toml 2024-06-23 01:48:41 -07:00
cross_crate_inline.rs Remove all checks of IntrinsicDef::must_be_overridden except for the actual overrides in codegen 2024-03-19 09:19:58 +00:00
ctfe_limit.rs Add blank lines after module-level //! comments. 2024-06-20 09:23:20 +10:00
dataflow_const_prop.rs ScalarInt: size mismatches are a bug, do not delay the panic 2024-06-10 13:43:16 +02:00
dead_store_elimination.rs Remove extern crate rustc_middle from rustc_mir_transform. 2024-05-13 08:20:18 +10:00
deduce_param_attrs.rs consistency rename: language item -> lang item 2024-04-17 13:00:43 +02:00
deduplicate_blocks.rs Merge dead bb pruning and unreachable bb deduplication. 2024-01-07 15:12:10 +00:00
deref_separator.rs remove redundant imports 2023-12-10 10:56:22 +08:00
dest_prop.rs Revert "Auto merge of #115105 - cjgillot:dest-prop-default, r=oli-obk" 2024-05-31 00:22:40 +00:00
dump_mir.rs Show files produced by --emit foo in json artifact notifications 2024-04-19 08:31:41 -04:00
early_otherwise_branch.rs Don't change the otherwise of the switch 2024-04-08 19:20:07 +08:00
elaborate_box_derefs.rs Remove extern crate rustc_middle from rustc_mir_transform. 2024-05-13 08:20:18 +10:00
elaborate_drops.rs Reformat mir! macro invocations to use braces. 2024-06-03 13:24:44 +10:00
errors.rs Remove redundant argument from subdiagnostic method 2024-06-18 15:42:11 +00:00
ffi_unwind_calls.rs Stabilise c_unwind 2024-06-19 13:54:51 +01:00
function_item_references.rs Rename Unsafe to Safety 2024-05-17 18:33:37 -03:00
gvn.rs GVN away PtrToPtr-then-Transmute when possible 2024-06-22 20:34:09 -07:00
inline.rs Save 2 pointers in TerminatorKind (96 → 80 bytes) 2024-06-21 18:02:05 -07:00
instsimplify.rs Save 2 pointers in TerminatorKind (96 → 80 bytes) 2024-06-21 18:02:05 -07:00
jump_threading.rs interpret: get rid of 'mir lifetime everywhere 2024-05-27 08:25:57 +02:00
known_panics_lint.rs MIR visitor: constant -> const_operand 2024-06-13 15:37:13 +02:00
large_enums.rs Simplify use crate::rustc_foo::bar occurrences. 2024-05-08 16:57:31 +10:00
lib.rs Save 2 pointers in TerminatorKind (96 → 80 bytes) 2024-06-21 18:02:05 -07:00
lint.rs Add blank lines after module-level //! comments. 2024-06-20 09:23:20 +10:00
lower_intrinsics.rs Save 2 pointers in TerminatorKind (96 → 80 bytes) 2024-06-21 18:02:05 -07:00
lower_slice_len.rs Replace NormalizeArrayLen with GVN 2024-06-20 22:16:59 -07:00
match_branches.rs ScalarInt: size mismatches are a bug, do not delay the panic 2024-06-10 13:43:16 +02:00
mentioned_items.rs Make builtin_deref just return a Ty 2024-05-09 22:55:00 -04:00
multiple_return_terminators.rs remove redundant imports 2023-12-10 10:56:22 +08:00
nrvo.rs Revert "Auto merge of #115105 - cjgillot:dest-prop-default, r=oli-obk" 2024-05-31 00:22:40 +00:00
pass_manager.rs Only split by-ref/by-move futures for async closures 2024-03-19 16:59:23 -04:00
prettify.rs remove redundant imports 2023-12-10 10:56:22 +08:00
promote_consts.rs Auto merge of #125853 - tesuji:promote-fail-fast, r=cjgillot 2024-06-21 16:00:14 +00:00
ref_prop.rs Remove extern crate rustc_middle from rustc_mir_transform. 2024-05-13 08:20:18 +10:00
remove_noop_landing_pads.rs Avoid debug logging entire MIR body 2024-02-15 15:54:28 +01:00
remove_place_mention.rs remove redundant imports 2023-12-10 10:56:22 +08:00
remove_storage_markers.rs Move condition enabling the pass to is_enabled 2024-01-23 20:58:44 +01:00
remove_uninit_drops.rs remove redundant imports 2023-12-10 10:56:22 +08:00
remove_unneeded_drops.rs Merge dead bb pruning and unreachable bb deduplication. 2024-01-07 15:12:10 +00:00
remove_zsts.rs Add CoroutineClosure to TyKind, AggregateKind, UpvarArgs 2024-02-06 02:22:58 +00:00
required_consts.rs MIR visitor: constant -> const_operand 2024-06-13 15:37:13 +02:00
reveal_all.rs MIR visitor: constant -> const_operand 2024-06-13 15:37:13 +02:00
shim.rs Save 2 pointers in TerminatorKind (96 → 80 bytes) 2024-06-21 18:02:05 -07:00
simplify_branches.rs simplify_branches: add comment 2024-03-24 12:53:03 +01:00
simplify_comparison_integral.rs ScalarInt: size mismatches are a bug, do not delay the panic 2024-06-10 13:43:16 +02:00
simplify.rs rustc_index: Add a ZERO constant to index types 2024-04-03 19:06:22 +03:00
single_use_consts.rs Try keeping a bitset for which locals need debuginfo updates 2024-06-10 00:06:02 -07:00
sroa.rs Use is_lang_item more aggressively 2024-06-14 16:54:29 -04:00
ssa.rs Remove extern crate rustc_middle from rustc_mir_transform. 2024-05-13 08:20:18 +10:00
unreachable_enum_branching.rs Remove extern crate rustc_middle from rustc_mir_transform. 2024-05-13 08:20:18 +10:00
unreachable_prop.rs Remove extern crate rustc_middle from rustc_mir_transform. 2024-05-13 08:20:18 +10:00
validate.rs More GVN for PtrMetadata 2024-06-20 22:16:59 -07:00