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

fix: subtype check for literal and union types (part 2) #1289

Merged
merged 2 commits into from
Dec 28, 2024

Conversation

lars-reimann
Copy link
Member

Summary of Changes

The type checker previously did not regard literal<1, ""> as a subtype of union<literal<1>, literal<"">. This is fixed now.

Copy link

github-actions bot commented Dec 28, 2024

🦙 MegaLinter status: ✅ SUCCESS

Descriptor Linter Files Fixed Errors Elapsed time
✅ REPOSITORY git_diff yes no 0.15s
✅ TYPESCRIPT eslint 2 0 0 4.5s
✅ TYPESCRIPT prettier 2 0 0 0.95s

See detailed report in MegaLinter reports
Set VALIDATE_ALL_CODEBASE: true in mega-linter.yml to validate all sources, not only the diff

MegaLinter is graciously provided by OX Security

Copy link

codecov bot commented Dec 28, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.72%. Comparing base (911881c) to head (f57ff4e).
Report is 18 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1289   +/-   ##
=======================================
  Coverage   99.72%   99.72%           
=======================================
  Files         114      114           
  Lines       12805    12811    +6     
  Branches     4208     4212    +4     
=======================================
+ Hits        12770    12776    +6     
  Misses         35       35           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@lars-reimann lars-reimann merged commit 56284cf into main Dec 28, 2024
7 checks passed
@lars-reimann lars-reimann deleted the type-checking-literals-2 branch December 28, 2024 18:53
lars-reimann pushed a commit that referenced this pull request Jan 4, 2025
## [0.23.0](v0.22.0...v0.23.0) (2025-01-04)

### Features

* categorize API elements ([#1285](#1285)) ([3275900](3275900)), closes [#1243](#1243)
* optional error messages for constraints ([#1275](#1275)) ([fce761c](fce761c)), closes [#1082](#1082)
* prevent editing built-in stubs ([#1282](#1282)) ([d02c30a](d02c30a))
* show placeholders in outline ([#1286](#1286)) ([3880bfe](3880bfe))

### Bug Fixes

* subtype check for literal and union types ([#1288](#1288)) ([911881c](911881c))
* subtype check for literal and union types (part 2) ([#1289](#1289)) ([56284cf](56284cf))
* type inference for lambdas and their parameters ([#1304](#1304)) ([a9e070f](a9e070f))
@lars-reimann
Copy link
Member Author

🎉 This PR is included in version 0.23.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@lars-reimann lars-reimann added the released Included in a release label Jan 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
released Included in a release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant