mirror of
https://github.com/danbulant/oxc
synced 2026-05-24 20:32:10 +00:00
perf(parser): remove an extra branch from parse_member_expression_rhs hot path (#896)
This commit is contained in:
parent
38aa3205b4
commit
1793397f20
1 changed files with 1 additions and 1 deletions
|
|
@ -540,7 +540,7 @@ impl<'a> Parser<'a> {
|
||||||
in_optional_chain: &mut bool,
|
in_optional_chain: &mut bool,
|
||||||
) -> Result<Expression<'a>> {
|
) -> Result<Expression<'a>> {
|
||||||
let mut lhs = lhs;
|
let mut lhs = lhs;
|
||||||
while !self.at(Kind::Eof) {
|
loop {
|
||||||
lhs = match self.cur_kind() {
|
lhs = match self.cur_kind() {
|
||||||
Kind::LBrack => self.parse_computed_member_expression(lhs_span, lhs, false)?,
|
Kind::LBrack => self.parse_computed_member_expression(lhs_span, lhs, false)?,
|
||||||
Kind::Dot => self.parse_static_member_expression(lhs_span, lhs, false)?,
|
Kind::Dot => self.parse_static_member_expression(lhs_span, lhs, false)?,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue