* Propegate saved variance flags from cached comparisons
* Propegate variance a bit more selectively
* Add test
* Remove now-redundant code
* Fix misspelling and remove unneeded branch
* Improved error messages when indexing an object type with a literal string, a literal string union or a string.
* Added more specific message when using the indexing operator with an incompatible index argument.
* Fixed spelling and error message.
* Allow JS with isolated modules
Previously legacy JS code was not allowed; it was required to use ES6
module syntax. Unfortunately, the check happens after parsing but before
binding, and the commonjs module indicator isn't set until binding
because it's not syntactically simple like the ES6 module indicator,
which is set during parsing.
So I decided that JS should be allowed during isolatedModules
unconditionally. We're not going to be transforming it anyway.
* Update baselines
* Switch test to outDir instead of noEmit
* Add this-parameter workaround to Array.filter
Allows anys.filter(Boolean) to once again return any[], not unknown[].
* Add any constraint to Boolean factory function
I want to test how well this works.
* Remove Boolean factory type guard
* Remove typeGuardBoolean test
* Modify flow loop cache key to include all inputs
* Add test case, cache similarly to loop cache, reuse loop cache key (now corrected)
* Use simpler singleton key and type cache for FlowAssignment nodes
* Add unmeasurable variance kind for marking types whose variance result is unreliable
* Remove now-unneeded nongeneric checks
* Add rule allowing `Readonly<any>` to be `any` instead of `{readonly [index: string]: any}`
* All Unmeasurable variances to still shortcut structural comparisons in some cases
* Separate unmeasurable from unreliable to reduce the impact of this change, for now
* Fix lint
* Remove Readonly<any> -> any callout
* Add fix for circularity error triggered by deep signature return type comparisons with `this` types
* give suggestions when index signature given
* add tests for noImplicitAny indexing on Object
* remove comments regarding error messages
* recommend set if el is on RHS of assignment else get
* add new baseline tests
fix#31012
Since the purpose of isolatedModules: true is to
do extra validation to ensure that separate
compilation is safe
Allowing emit in the presence of errors is
compatible with that intention.
Signed-off-by: Max Heiber <max.heiber@gmail.com>