Redundant `'outer_loop` label in selector parser after loop refactoring
Categories
(Core :: CSS Parsing and Computation, enhancement)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox148 | --- | fixed |
People
(Reporter: nabeyang, Assigned: nabeyang)
Details
Attachments
(1 file)
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36
Steps to reproduce:
I reviewed the selector parsing code and noticed that the 'outer_loop label
is still present even though the nested loop structure that previously
required it has been removed.
Actual results:
The code still uses a labeled loop ('outer_loop) and explicit
break 'outer_loop; statements, even though a plain break; would have the
same effect.
Expected results:
Since the parser no longer contains a nested loop that requires breaking out
of an outer scope, the 'outer_loop label should be removed, and
break 'outer_loop; should be replaced with a plain break;.
| Assignee | ||
Comment 1•2 months ago
|
||
The selector parser previously relied on a labeled 'outer_loop to break out
of nested loops when parsing combinators.
After recent refactoring, the nested loop structure no longer exists, and all
break statements target the same loop. As a result, the 'outer_loop label and
the labeled break 'outer_loop; are redundant.
This change removes the unused loop label and replaces the labeled break with a
plain break;, simplifying the control flow without changing behavior.
Updated•2 months ago
|
Comment 3•2 months ago
|
||
| bugherder | ||
Updated•1 month ago
|
Description
•