Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit bdd5a9a

Browse files
committed
Auto merge of rust-lang#117727 - saethlin:inline-derived-fmt, r=<try>
Emit #[inline] on derive(Debug) Breaking out part of rust-lang#116583 (comment) r? `@ghost`
2 parents 90fdc1f + 857e13c commit bdd5a9a

File tree

1 file changed

+1
-1
lines changed
  • compiler/rustc_builtin_macros/src/deriving

1 file changed

+1
-1
lines changed

compiler/rustc_builtin_macros/src/deriving/debug.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ pub fn expand_deriving_debug(
3333
explicit_self: true,
3434
nonself_args: vec![(fmtr, sym::f)],
3535
ret_ty: Path(path_std!(fmt::Result)),
36-
attributes: ast::AttrVec::new(),
36+
attributes: attributes: thin_vec![cx.attr_word(sym::inline, span)],
3737
fieldless_variants_strategy:
3838
FieldlessVariantsStrategy::SpecializeIfAllVariantsFieldless,
3939
combine_substructure: combine_substructure(Box::new(|a, b, c| {

0 commit comments

Comments
 (0)