Skip to content

Commit f314ece

Browse files
committed
Remove mutbl argument from create_struct_patterns.
It's always `ast::Mutability::Not`.
1 parent a42e50e commit f314ece

File tree

1 file changed

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

1 file changed

+1
-4
lines changed

compiler/rustc_builtin_macros/src/deriving/generic/mod.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1072,7 +1072,6 @@ impl<'a> MethodDef<'a> {
10721072
struct_path,
10731073
struct_def,
10741074
&prefixes,
1075-
ast::Mutability::Not,
10761075
use_temporaries,
10771076
);
10781077

@@ -1219,7 +1218,6 @@ impl<'a> MethodDef<'a> {
12191218
variant_path,
12201219
&variant.data,
12211220
&prefixes,
1222-
ast::Mutability::Not,
12231221
use_temporaries,
12241222
)
12251223
.into_iter()
@@ -1453,7 +1451,6 @@ impl<'a> TraitDef<'a> {
14531451
struct_path: ast::Path,
14541452
struct_def: &'a VariantData,
14551453
prefixes: &[String],
1456-
mutbl: ast::Mutability,
14571454
use_temporaries: bool,
14581455
) -> Vec<P<ast::Pat>> {
14591456
prefixes
@@ -1465,7 +1462,7 @@ impl<'a> TraitDef<'a> {
14651462
let binding_mode = if use_temporaries {
14661463
ast::BindingMode::ByValue(ast::Mutability::Not)
14671464
} else {
1468-
ast::BindingMode::ByRef(mutbl)
1465+
ast::BindingMode::ByRef(ast::Mutability::Not)
14691466
};
14701467
let ident = self.mk_pattern_ident(prefix, i);
14711468
let path = ident.with_span_pos(sp);

0 commit comments

Comments
 (0)