Rename some Diagnostic setters.
`Diagnostic` has 40 methods that return `&mut Self` and could be considered setters. Four of them have a `set_` prefix. This doesn't seem necessary for a type that implements the builder pattern. This commit removes the `set_` prefixes on those four methods.
This commit is contained in:
@@ -70,7 +70,7 @@ fn generic_arg_mismatch_err(
|
||||
Res::Err => {
|
||||
add_braces_suggestion(arg, &mut err);
|
||||
return err
|
||||
.set_primary_message("unresolved item provided when a constant was expected")
|
||||
.primary_message("unresolved item provided when a constant was expected")
|
||||
.emit();
|
||||
}
|
||||
Res::Def(DefKind::TyParam, src_def_id) => {
|
||||
|
||||
Reference in New Issue
Block a user