Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Class field is incorrectly inlined #1267

Closed
Austaras opened this issue Sep 28, 2022 · 0 comments
Closed

Class field is incorrectly inlined #1267

Austaras opened this issue Sep 28, 2022 · 0 comments
Labels

Comments

@Austaras
Copy link

Bug report or Feature request?

Bug report

Version (complete output of terser -V or specific git commit)
terser playground

Complete CLI command or minify() options used
default options

terser input

class ClassA {
}
class ClassB {
    MyA = ClassA;
};

console.assert(new ClassB().MyA == new ClassB().MyA)

terser output or error

class ClassB {
    MyA=class {};
}

console.assert((new ClassB).MyA == (new ClassB).MyA);

which evaluates to false
Expected result
Result evaluates to true

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants