Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Emitter changes to fuse JS emitting and printing #4922

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

Merged
merged 4 commits into from
Jan 28, 2024

Conversation

gzm0
Copy link
Contributor

@gzm0 gzm0 commented Dec 30, 2023

No description provided.

@gzm0
Copy link
Contributor Author

gzm0 commented Jan 2, 2024

I have added a commit to use fromByte in KnowledgeGuardian (this change was still in #4917).

Copy link
Member

@sjrd sjrd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One nit, but otherwise LGTM.

ctor, // invalidated directly
memberMethods, // invalidated directly
exportedMembers.flatten // invalidated directly
ctor ++ memberMethods ++ exportedMembers.flatten // all 3 invalidated directly
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If these are all Lists, ::: is more efficient:

Suggested change
ctor ++ memberMethods ++ exportedMembers.flatten // all 3 invalidated directly
ctor ::: memberMethods ::: exportedMembers.flatten // all 3 invalidated directly

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed .

@gzm0 gzm0 force-pushed the emitter-changes branch 2 times, most recently from 57c062c to f40cd0d Compare January 28, 2024 11:14
gzm0 added 4 commits January 28, 2024 16:43
This allows us to invalidate generated exported members less
often (and in following commits, also class members).
Now that we have it, we might as well save some memory.
This simplifies buildClass. Thanks to the special version for
isJSClass, this will lead to acceptable invalidations (only if the
class kind changes, which should be rare).
This removes the only desugarExpr call from buildClass. Since we'll
stop caching buildClass going forward, this is important.
@gzm0 gzm0 merged commit aed2e05 into scala-js:main Jan 28, 2024
@gzm0 gzm0 deleted the emitter-changes branch January 29, 2024 13:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants