Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug Fix: upstream inference bug using createOptionFromNullable in a n…
…ested runtime type, closes #67
- Loading branch information
f715303
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gcanti I'm pretty sure we were using indirect typings of A and O (basically deduced from type's type) to prevent inferring to '{}' or 'any' in some cases.
But I'm unsure what's the state of affairs with the latest changes - that's very hard to follow.
It looks like we should create some type level regressions tests for the pattern we use as it appears to regularly break with typescript updates for any moderately advanced type usage.
Those regular breaking hurts a lot, specifically with a large code base.
And sometimes they're silent, leaving no trust in the typechecker.
Note: I'm referring to that very problem here microsoft/TypeScript#27994
P.S.: for the record; the last used pattern was due to another upstream bug:
4e5238d#diff-e3f1fa5f10d7deb8394a40ef7f01d814