Skip to content

Fix emit for export {...} with ES6 target and non-ES6 modules #5176

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 3 commits into from
Oct 8, 2015

Conversation

ahejlsberg
Copy link
Member

Fixes #5175.

@ahejlsberg
Copy link
Member Author

@mhegazy @weswigham You may want to look this over.

}
type T = number;
import a = M.x;

Copy link
Member

Choose a reason for hiding this comment

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

Add in a reassignment to v (ie, v = 10) here. Observe that we emit v = 10 but no corresponding exports.v = v. I'm not sure lifting all the exports from where the export statement is to wherever the variable's declaration is is correct for this export form.

Copy link
Member Author

Choose a reason for hiding this comment

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

That's an orthogonal issue already being discussed in #4101.

Copy link
Member

Choose a reason for hiding this comment

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

Ahh, okay, didn't know about the old issue.

@mhegazy
Copy link
Contributor

mhegazy commented Oct 8, 2015

👍

@weswigham
Copy link
Member

👍

ahejlsberg added a commit that referenced this pull request Oct 8, 2015
Fix emit for `export {...}` with ES6 target and non-ES6 modules
@ahejlsberg ahejlsberg merged commit bff9148 into master Oct 8, 2015
@ahejlsberg ahejlsberg deleted the emitExportAssignments branch October 8, 2015 20:19
@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants