mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-27 21:42:53 +00:00
JSSpecCompiler: Ignore notes in algorithm steps
This commit is contained in:
parent
ba61b61d67
commit
f7c952f842
Notes:
sideshowbarker
2024-07-16 19:57:55 +09:00
Author: https://github.com/DanShaders
Commit: f7c952f842
Pull-request: https://github.com/SerenityOS/serenity/pull/23123
Reviewed-by: https://github.com/ADKaster ✅
6 changed files with 30 additions and 8 deletions
|
@ -598,10 +598,16 @@ TextParseErrorOr<Tree> TextParser::parse_else(Tree else_branch)
|
|||
}
|
||||
|
||||
// <simple_step> | <inline_if>
|
||||
TextParseErrorOr<Tree> TextParser::parse_step_without_substeps()
|
||||
TextParseErrorOr<NullableTree> TextParser::parse_step_without_substeps()
|
||||
{
|
||||
auto rollback = rollback_point();
|
||||
|
||||
// NOTE: ...
|
||||
if (auto result = consume_word("NOTE:"sv); !result.is_error()) {
|
||||
rollback.disarm();
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// <simple_step>
|
||||
if (auto result = parse_simple_step_or_inline_if_branch(); !result.is_error()) {
|
||||
rollback.disarm();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue