1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 16:47:36 +00:00

Everywhere: Use '_{short_,}string' literals more

This mostly updates code what was written before but merged after these
were added.
This commit is contained in:
Linus Groh 2023-02-28 13:50:29 +00:00
parent d0ba5f2ed7
commit 51c3967516
15 changed files with 94 additions and 95 deletions

View file

@ -716,7 +716,7 @@ ErrorOr<Lexer::ReductionResult> Lexer::reduce_arithmetic_expansion()
expansion.range.length = m_state.position.end_offset - expansion.range.start - m_state.position.start_offset;
return ReductionResult {
.tokens = { Token::continuation(String::from_utf8_short_string("$(("sv)) },
.tokens = { Token::continuation("$(("_short_string) },
.next_reduction = m_state.previous_reduction,
};
}
@ -791,7 +791,7 @@ ErrorOr<Lexer::ReductionResult> Lexer::reduce_command_or_arithmetic_substitution
{
if (m_lexer.is_eof()) {
return ReductionResult {
.tokens = { Token::continuation(String::from_utf8_short_string("$("sv)) },
.tokens = { Token::continuation("$("_short_string) },
.next_reduction = m_state.previous_reduction,
};
}
@ -835,7 +835,7 @@ ErrorOr<Lexer::ReductionResult> Lexer::reduce_extended_parameter_expansion()
if (m_lexer.is_eof()) {
return ReductionResult {
.tokens = { Token::continuation(String::from_utf8_short_string("${"sv)) },
.tokens = { Token::continuation("${"_short_string) },
.next_reduction = m_state.previous_reduction,
};
}