Skip to content

fixStrictClassInitialization: Don't provide a default for string or number#24767

Merged
2 commits merged into
masterfrom
fixStrictClassInitialization_string_number
Jun 7, 2018
Merged

fixStrictClassInitialization: Don't provide a default for string or number#24767
2 commits merged into
masterfrom
fixStrictClassInitialization_string_number

Conversation

@ghost
Copy link
Copy Markdown

@ghost ghost commented Jun 7, 2018

@ghost ghost requested a review from mhegazy June 7, 2018 20:32
else if (type.flags & TypeFlags.Number) {
return createNumericLiteral("0");
}
else if (type.flags & TypeFlags.Boolean) {
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Also have to change this since a foo | boolean union doesn't decompose to something containing boolean, it decomposes to boolean literal types.

@ghost ghost merged commit 48dedac into master Jun 7, 2018
@ghost ghost deleted the fixStrictClassInitialization_string_number branch June 7, 2018 22:03
@microsoft microsoft locked as resolved and limited conversation to collaborators Oct 21, 2025
This pull request was closed.
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.

1 participant