mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-08-24 04:14:14 +00:00
Forbid visibility qualifiers in traits
This commit is contained in:
parent
a09b5b91ae
commit
1860f9ab43
4 changed files with 131 additions and 1 deletions
|
@ -82,6 +82,7 @@ pub enum SyntaxErrorKind {
|
|||
InvalidBlockAttr,
|
||||
InvalidMatchInnerAttr,
|
||||
InvalidTupleIndexFormat,
|
||||
VisibilityNotAllowed,
|
||||
}
|
||||
|
||||
impl fmt::Display for SyntaxErrorKind {
|
||||
|
@ -99,6 +100,9 @@ impl fmt::Display for SyntaxErrorKind {
|
|||
}
|
||||
ParseError(msg) => write!(f, "{}", msg.0),
|
||||
EscapeError(err) => write!(f, "{}", err),
|
||||
VisibilityNotAllowed => {
|
||||
write!(f, "unnecessary visibility qualifier")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue