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

refactor: Merge type unwrapping for types into one step type aliases #104

Merged
merged 4 commits into from
Mar 4, 2024

Conversation

kitten
Copy link
Member

@kitten kitten commented Mar 4, 2024

Summary

Previously, to unwrap NON_NULL-like type references, we would have an outer type handling T | null for nullable types, and an inner type handling other refrences.
These two steps can be merged by adding an extra argument to the recursive parts of the type reference handler.

This should make some of these types more compact.

Set of changes

  • Merge unwrapType with _unwrapTypeRec into unwrapTypeRec in selection.ts
  • Merge unwrapType with _unwrapTypeRec into unwrapTypeRec in variables.ts
  • Merge unwrapTypeRef with _unwrapTypeRefRec into unwrapTypeRefRec in variables.ts

@kitten kitten requested a review from JoviDeCroock March 4, 2024 10:08
Copy link

changeset-bot bot commented Mar 4, 2024

🦋 Changeset detected

Latest commit: 7d3ffce

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@kitten kitten merged commit 26e4993 into main Mar 4, 2024
2 checks passed
@kitten kitten deleted the refactor/unwrap-type branch March 4, 2024 11:00
@github-actions github-actions bot mentioned this pull request Mar 3, 2024
@kitten kitten added this to the Are We Fast Yet? milestone Mar 22, 2024
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.

None yet

2 participants