Add Mutability::{is_mut,is_not}
This commit is contained in:
parent
9b9c7d0ecc
commit
da40965300
14 changed files with 29 additions and 26 deletions
|
@ -398,7 +398,7 @@ impl<'a> State<'a> {
|
|||
}
|
||||
hir::ForeignItemKind::Static(t, m) => {
|
||||
self.head("static");
|
||||
if m == hir::Mutability::Mut {
|
||||
if m.is_mut() {
|
||||
self.word_space("mut");
|
||||
}
|
||||
self.print_ident(item.ident);
|
||||
|
@ -519,7 +519,7 @@ impl<'a> State<'a> {
|
|||
}
|
||||
hir::ItemKind::Static(ty, m, expr) => {
|
||||
self.head("static");
|
||||
if m == hir::Mutability::Mut {
|
||||
if m.is_mut() {
|
||||
self.word_space("mut");
|
||||
}
|
||||
self.print_ident(item.ident);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue