Fails to type check annotated code
Open
- Dominant language
- TypeScript
- Stars
- 37
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
Here is an example of the code:
```ts
type Just = {
x: T
}
enum Maybe {
None,
Just
}
const delta = (a:int, b:int):Maybe => {
if a == b {
None
} else {
Just{x: b - a}
}
}
```


Only thing that seems to works is
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the type-checking failure with the annotated TypeScript example in the issue and compare it with the working form shown in the final image. Trace the type-checking entry point and identify the change needed for the example to type-check successfully.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100