We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b2be314 commit 10494c9Copy full SHA for 10494c9
compiler/parser/src/string_parser.rs
@@ -125,7 +125,7 @@ impl<'a> StringParser<'a> {
125
}
126
127
unicode_names2::character(&name)
128
- .ok_or(LexicalError::new(LexicalErrorType::UnicodeError, start_pos))
+ .ok_or_else(|| LexicalError::new(LexicalErrorType::UnicodeError, start_pos))
129
130
131
fn parse_escaped_char(&mut self) -> Result<String, LexicalError> {
0 commit comments