forked from extern/nushell
Clippy
This commit is contained in:
parent
1e1e12b027
commit
6f5f1fa43a
@ -611,16 +611,14 @@ pub fn parse_hide(
|
|||||||
.iter()
|
.iter()
|
||||||
.map(|(name, _)| name.clone())
|
.map(|(name, _)| name.clone())
|
||||||
.collect()
|
.collect()
|
||||||
|
} else if import_pattern.members.is_empty() {
|
||||||
|
// The pattern head can be e.g. a function name, not just a module
|
||||||
|
vec![import_pattern.head.clone()]
|
||||||
} else {
|
} else {
|
||||||
if import_pattern.members.is_empty() {
|
return (
|
||||||
// The pattern head can be e.g. a function name, not just a module
|
garbage_statement(spans),
|
||||||
vec![import_pattern.head.clone()]
|
Some(ParseError::ModuleNotFound(spans[1])),
|
||||||
} else {
|
);
|
||||||
return (
|
|
||||||
garbage_statement(spans),
|
|
||||||
Some(ParseError::ModuleNotFound(spans[1])),
|
|
||||||
);
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
// This kind of inverts the import pattern matching found in parse_use()
|
// This kind of inverts the import pattern matching found in parse_use()
|
||||||
|
Loading…
Reference in New Issue
Block a user