Use correct ParseError (#5431)

This commit is contained in:
Tom 2022-05-04 20:41:32 +01:00 committed by GitHub
parent 6623ed9061
commit 02a3430ef0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1109,8 +1109,8 @@ pub fn parse_module_block(
}
_ => (
garbage_pipeline(&pipeline.commands[0].parts),
Some(ParseError::UnexpectedKeyword(
"expected def or export keyword".into(),
Some(ParseError::ExpectedKeyword(
"def or export keyword".into(),
pipeline.commands[0].parts[0],
)),
),