mirror of
https://github.com/rust-lang/rust.git
synced 2026-06-02 06:28:20 +03:00
Preventing moving out of the trait item kind
This commit is contained in:
@@ -1617,7 +1617,7 @@ fn visit_trait_item(&mut self, ti: &'a ast::TraitItem) {
|
||||
gate_feature_post!(&self, const_fn, ti.span, "const fn is unstable");
|
||||
}
|
||||
}
|
||||
ast::TraitItemKind::Type(_, default) => {
|
||||
ast::TraitItemKind::Type(_, ref default) => {
|
||||
// We use two if statements instead of something like match guards so that both
|
||||
// of these errors can be emitted if both cases apply.
|
||||
if default.is_some() {
|
||||
|
||||
Reference in New Issue
Block a user