forked from microsoft/TypeScript
-
Notifications
You must be signed in to change notification settings - Fork 15
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
Private name errors #2
Closed
jbhoosreddy
wants to merge
15
commits into
bloomberg:es-private-fields
from
jbhoosreddy:private-name-errors
Closed
Private name errors #2
jbhoosreddy
wants to merge
15
commits into
bloomberg:es-private-fields
from
jbhoosreddy:private-name-errors
Conversation
This file contains 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
start the work for basic errors. Plan for developing error spec: PR into the private-name-errors branch with example files in tests/cases/classes/privateNames. In those files, have sample code. If a line is interesting and does not error, end it with // OK If a line is interesting and does error, end it with // Error:
* errrors for mixing modifiers and private names The plan was to allow these to be mixed, but I think it's better to not allow any modifiers with private names because afaik there is no use case for: private #foo It has the disadvantage of being more restrictive than `#foo` (no structural typing for classes with `private`) but does not have any of the advantages of `private` * tests case for #constructor reserved * Update privateNameContructorReserved.ts
mheiber
pushed a commit
that referenced
this pull request
Jul 2, 2018
* jenkinsfile * add npm run build step * lint * baseline change * accept more baselines * accept baselines * fix-scanner * baselines again
joeywatts
referenced
this pull request
in joeywatts/TypeScript
Jul 3, 2018
* jenkinsfile * add npm run build step * lint * baseline change * accept more baselines * accept baselines * fix-scanner * baselines again
joeywatts
referenced
this pull request
in joeywatts/TypeScript
Aug 21, 2018
* jenkinsfile * add npm run build step * lint * baseline change * accept more baselines * accept baselines * fix-scanner * baselines again
@jbhoosreddy @mheiber @joeywatts What's the status of this PR? It's been hanging around while. |
superceded by other PRs, esp. the checker PR. |
dragomirtitian
pushed a commit
that referenced
this pull request
Aug 22, 2023
1. Reformat union types 2. Do not add type annotation when not needed 3. Fix tests for #2 changes. Signed-off-by: Hana Joo <hanajoo@google.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is an effort to identify all the possible errors that might happen when using private fields in Typescript. As @mheiber said, this is a good opportunity to give developers good and meaningful errors when they run into these situations.
Co-authored by: @mheiber, @joeywatts