* WIP
* Add extension error back unless noEmit is set
* Add non-relative tests
* Add error for importing from declaration file
* Update unit test
* Add explicit flag for importing from .ts extensions
* Add module specifier resolution changes
* Add auto-import tests
* Disallow relative imports into node_modules
* Ensure auto-imports don’t suggest ./node_modules;
* Test a non-portable declaration emit issue
* Test auto-importing TSX file
* Update path completions
* Fix lint due to merge
* Remove minimal-specific stuff
* Remove minimal tests
* Update unit tests
* Add options
* Add customConditions option
* Add first tests
* CJS constructs are not allowed
* Add another test
* Fix extension adding/replacing priority
* Update test to reflect the choice not to block on unrecognized extensions
* Add auto-imports and string completions tests
* Revamp string completions ending preferences
* Comment test
* Auto-imports of declaration files cannot use .ts extension
* Have declaration file auto imports default to extensionless instead
* Add test for custom conditions
* Fix indentation
* Add baseline showing resolvePackageJsonImports/Exports compatibility
* Fix test and prevent CJS require from resolving
* Update unit test baselines
* Fix bad merge conflict resolution
* Make resolvedUsingTsExtension optional
* Update missed baselines
* Revert now-unnecessary API implementation changes
* Clean up
* Update baselines to es5 emit
* Rename to `bundler`
* Move .symbol to Declaration
* simplify some factories
* Move localSymbol to Declaration
* Ensure JSDocContainer types are properly initialized
* Move contextualType from Node to NodeLinks
* Move 'locals' and 'nextContainer' out of Node
* Move 'flowNode' out of 'Node'
* Pre-define endFlowNode/returnFlowNode
* Pre-define some SourceFile properties and a more stable cloneNode
* Don't add excess properties to type nodes in typeToTypeNode
* Refactor wrapSymbolTrackerToReportForContext to improve perf
* tsconfig.extends as array
* Updated baselines
* Changes for pr
* Changes for pr comments
* Fixed formatting and edited a test
* Resolved errors after a merge conflict
* Added "string | list" type implentation
* Removed string | list type implementation
* Fixed formatting
* Added compiler test
* Resolving programUpdate errors
* Fixing commandLineParser error
* feat(49323): add support throws jsdoc tag
* change "name" to "typeExpression". parse "exception" as a synonym for "throws"
* include typeExpression from the throws tag in the quick info
* add JSDocThrowsTag to ForEachChildNodes
* Fixed tuple types indexed by a type parameter
* If only there was a tool to add that missing semicolon for me
* Rename to baseConstraint
Co-authored-by: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com>
* retroactive approach to remove duplicate diagnostics
* use code instead of messageText, update test
* use existing de-dupe function
* rename test and baselines
* add fourslash test for better assertion of fix
* review feedback: move deduplicate to getDiagnosticsHelper
* accept baseline with sorted diagnostics
* remove newline
* Change the default emit target to ES5
* Add baseline update
* Remove tests with a hardcoded sourcemap in it
* Update hardcoded tests
* Merge with main
* Restore tests
* Make the non relative name resolution cache generic
* Add cache for non relative type reference resolution
* Add getter only methods so we can use these in future for sharing resolutions across the projects
* Mark existing non relative module name cache getOrCreate as deprecated
* Prefer getters for getting directory results
* Fix missed errors in switch when using union of literal and non-literal types (#38686)
This commit makes it so we don’t use the base type of literals when checking comparability in switch. The comparability checks handle that case already, is my understanding, so we don’t need to clobber the type before actually doing the check, causing missed errors.
When comparing the types in switch, if a union with a literal and a non-literal was used, the compiler in `checker.ts` would automatically get the base type of all parts of the union, resulting in missed errors. For example, if the union of the non-literal `number` and literal `"hello"` was compared to the literal `"world"` in a switch case, the compiler would miss that they’re actually not comparable.
Maybe someone can tell me why we were getting the base type before checking comparability, rather than relying on the logic within the comparability checks to handle literal/base type comparability?
* Fix lint (whitespace) issue in checker.ts by running lint with fix flag.
* Remove webServer
First draft; I may move some things around to be more readable.
* Refactor moved code
1. Move StartSessionOptions to common next to where it's first used.
2. Inline single-use BaseLogger base class into its only child class,
Logger.
3. Start using direct imports, eg `import {} from './common'`. I hope
this is OK?!
* Fix lint
* move imports back to namespace import
* hereby tsserver: remove exportIsTsObject