mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 20:28:11 +00:00
LibRegex: Convert StringBuilder::appendf() => AK::Format
This commit is contained in:
parent
840b908c0b
commit
79ff1902aa
2 changed files with 8 additions and 8 deletions
|
@ -44,12 +44,12 @@ template<class Parser>
|
|||
String Regex<Parser>::error_string(Optional<String> message) const
|
||||
{
|
||||
StringBuilder eb;
|
||||
eb.appendf("Error during parsing of regular expression:\n");
|
||||
eb.appendf(" %s\n ", pattern_value.characters());
|
||||
eb.append("Error during parsing of regular expression:\n");
|
||||
eb.appendff(" {}\n ", pattern_value);
|
||||
for (size_t i = 0; i < parser_result.error_token.position(); ++i)
|
||||
eb.append(" ");
|
||||
eb.append(' ');
|
||||
|
||||
eb.appendf("^---- %s", message.value_or(get_error_string(parser_result.error)).characters());
|
||||
eb.appendff("^---- {}", message.value_or(get_error_string(parser_result.error)));
|
||||
return eb.build();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue