FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Improve `super.x` output by liuxingbaoyu · Pull Request #16374 · babel/babel · GitHub

/ babel Public

Improve super.x output - #16374

Merged
liuxingbaoyu merged 11 commits into
babel:mainfrom
liuxingbaoyu:super.prop
Jul 23, 2024
Merged

liuxingbaoyu merged 11 commits into
babel:mainfrom
liuxingbaoyu:super.prop

Conversation

liuxingbaoyu commented Mar 21, 2024
edited
Loading

Copy link
Copy Markdown
Member
Q                       A
Fixed Issues? Fixes #1, Fixes #2
Patch: Bug Fix?
Major: Breaking Change?
Minor: New Feature?
Tests Added + Pass? Yes
Documentation PR Link
Any Dependency Changes?
License MIT

I personally don't like having to call getPrototypeOf every time because it's slow, but we have a test that relies on this behavior.

babel-bot commented Mar 21, 2024
edited
Loading

Copy link
Copy Markdown
Collaborator

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/57350

liuxingbaoyu marked this pull request as draft March 22, 2024 00:36
liuxingbaoyu marked this pull request as ready for review March 22, 2024 01:14
liuxingbaoyu added the PR: Output optimization 🔬 A type of pull request used for our changelog categories label Mar 22, 2024

nicolo-ribaudo commented Jun 21, 2024
edited
Loading

Copy link
Copy Markdown
Member

Finally reviewing this, sorry it took so long.

I personally don't like having to call getPrototypeOf every time because it's slow, but we have a test that relies on this behavior.

This is covered by the constantSuper assumption, right?


Can you add a test for the execution order between property access and arguments evaluation?

let argsEval = false;
let err = {};

class A {
  get x() { throw {} }
}

class B extends A {
  method() {
    super.x(argsEval = true);
  }
}

expect(() => new B().method()).toThrow(err);
expect(argsEval).toBe(false);

liuxingbaoyu force-pushed the super.prop branch 2 times, most recently from dd1bc89 to 92e2168 Compare June 25, 2024 06:34
liuxingbaoyu force-pushed the super.prop branch 2 times, most recently from 9c609ac to 8cb4293 Compare July 13, 2024 09:41
github-actions Bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label Oct 22, 2024
github-actions Bot locked as resolved and limited conversation to collaborators Oct 22, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

outdated A closed issue/PR that is archived due to age. Recommended to make a new issue PR: Output optimization 🔬 A type of pull request used for our changelog categories

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants


Back | FazBrowse Home | New Git URL