stc icon indicating copy to clipboard operation
stc copied to clipboard

Speedy TypeScript type checker

Results 150 stc issues
Sort by recently updated
recently updated
newest added

**Description:** I am not sure whether my fix is correct, so I am going to describe what I am doing here. This MR is fixing #211. The original issue's proposed...

# Problem https://github.com/dudykr/stc/blob/269f6c07676f728e667ca5fb4c80d7f17f66a98d/crates/stc_ts_type_checker/tests/conformance/types/objectTypeLiteral/constructSignatures/constructSignaturesWithOverloads2.ts#L15-L24 should pass, but stc fails to verify it. Currently we only check overloads for methods, so overload selection for `new` fails # Solution We should handle constructor...

bug
good first issue

# Problem https://github.com/dudykr/stc/blob/d8bb0e132d8ffdfa898c71165f7777d7bfb24eb3/crates/stc_ts_type_checker/tests/conformance/types/stringLiteral/typeArgumentsWithStringLiteralTypes01.ts#L87-L91 Even when generics arguments are specified by the user, `tsc` reports only one argument type mismatch error if it's a generic call. # Solution We should accept...

bug
good first issue

# Problem https://github.com/dudykr/stc/blob/36f243a4b4b3db1c2838365f695daa5138ac9a07/crates/stc_ts_type_checker/tests/conformance/types/typeRelationships/comparable/equalityStrictNulls.ts#L61-L68 ``` Wanted: [RefError { line: 61, column: 13, code: "TS18050" }, RefError { line: 63, column: 13, code: "TS18050" }, RefError { line: 65, column: 14, code:...

bug
good first issue

# Problem https://github.com/dudykr/stc/blob/56ae129a0674e81af048e2281653363876ccb11d/crates/stc_ts_type_checker/tests/conformance/types/tuple/arityAndOrderCompatibility01.ts#L1-L5 This type is treated almost as a tuple by `tsc`, but `stc` fails to verify it. It's because it extends `Array`. # Solution I think we should...

bug
good first issue

# Problem https://github.com/dudykr/stc/blob/56ae129a0674e81af048e2281653363876ccb11d/crates/stc_ts_type_checker/tests/conformance/types/objectTypeLiteral/indexSignatures/stringIndexerConstrainsPropertyDeclarations2.ts#L35-L39 ``` Wanted: [RefError { line: 16, column: 5, code: "TS2411" }, RefError { line: 23, column: 5, code: "TS2411" }, RefError { line: 24, column: 5, code:...

bug

https://github.com/dudykr/stc/blob/269f6c07676f728e667ca5fb4c80d7f17f66a98d/crates/stc_ts_type_checker/tests/conformance/types/literal/stringMappingOverPatternLiterals.ts#L2-L4 https://github.com/dudykr/stc/blob/269f6c07676f728e667ca5fb4c80d7f17f66a98d/crates/stc_ts_file_analyzer/src/analyzer/types/mod.rs#L1551-L1610 We are handling `Type::Lit` (at line 1557), but we have to handle `Type:::Tpl`, too. While handling `Type::Tpl`, we should return a new `Type::Tpl`. The expressions of `Type::Tpl` can...

enhancement
good first issue

We should handle `this` is nested scopes. This is required to handle cases like https://github.com/dudykr/stc/blob/2eadcd5ad1de5e045167ee532e51fc4295b02b7f/crates/stc_ts_type_checker/tests/conformance/es6/computedProperties/computedPropertyNames22_ES6.ts#L1-L9 Currently, we do not use the correct `this`. https://github.com/dudykr/stc/blob/2eadcd5ad1de5e045167ee532e51fc4295b02b7f/crates/stc_ts_file_analyzer/src/analyzer/expr/mod.rs#L2425-L2451 We should add `parent_for_this()` to `Scope`...

enhancement

https://github.com/dudykr/stc/blob/2eadcd5ad1de5e045167ee532e51fc4295b02b7f/crates/stc_ts_type_checker/tests/conformance/async/es6/asyncMethodWithSuper_es6.ts#L192-L215 This should pass, but `stc` fails with ``` thread 'conformance::async::es6::asyncMethodWithSuper_es6.ts' panicked at ' ============================================================ error[TS2322]: DebugContext( context: lhs = void; rhs = ''; context: `fail!()` called from assign/mod.rs:1712 AssignFailed...

bug
good first issue

# Problem https://github.com/dudykr/stc/blob/efd873e395fb9327f6cbd8be76a24678013269c4/crates/stc_ts_type_checker/tests/conformance/salsa/typeFromPropertyAssignment29.ts#L2-L9 Currently, stc does not support adding a property to type by assigning a property to function. But the function type is special, and we should support it.

enhancement