Use String::new() for empty strings.

This commit is contained in:
Stephen Chung
2022-08-21 17:35:44 +08:00
parent 248888ce0b
commit 2f02b30b6e
7 changed files with 25 additions and 27 deletions

View File

@@ -303,7 +303,7 @@ fn test_custom_syntax_raw() -> Result<(), Box<EvalAltResult>> {
.compile("hello hey")
.expect_err("should error")
.err_type(),
ParseErrorType::BadInput(LexError::ImproperSymbol("hey".to_string(), "".to_string()))
ParseErrorType::BadInput(LexError::ImproperSymbol("hey".to_string(), String::new()))
);
Ok(())