Commit 535542a8 authored by Joyee Cheung's avatar Joyee Cheung Committed by Commit Bot

[parser] use ParsePropertyInfo as out parameter in object/class literals

This patch refactors the parsing of object literal properties and
class literal properties, putting the out parameters into a pointer of
struct `ParsePropertyInfo`. This struct is also aware of its potition
so `ParsePropertyName()` can also use this information to error
when parsing a private name in an object literal. It also makes
sure that the `ClassLiteralProperty::Kind` are all inferred
from the `ParsePropertyKind` and get used right away instead of
being passed around as out parameters.

Bug: v8:8330
Change-Id: I4c52592dfcaa3c8df30c4aba4c46e5c675acb394
Reviewed-on: https://chromium-review.googlesource.com/c/1347904
Commit-Queue: Joyee Cheung <joyee@igalia.com>
Reviewed-by: 's avatarToon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#57876}
parent 6292fdb8
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment