Commit Graph

32018 Commits

Author SHA1 Message Date
Nathan Shively-Sanders ad85e4fd22 Fix gulp baseline-accept (#29301)
* Fix gulp baseline-accept

I think it was ported incorrectly from jake and then never used.

* Re-add read:false to baselineDelete
2019-01-08 11:20:54 -08:00
Wesley Wigham 19c72c758a Allow untyped calls on unions of untyped things (#29265) 2019-01-08 11:05:55 -08:00
Alexander T 52057ac4f6 Merge branch 'master' of https://github.com/Microsoft/TypeScript into bug/24542-bad-error-message-for-import-ing-an-export 2019-01-08 10:55:11 +02:00
Alexander T 945eed8d9b PR feedback: change error #2497 message 2019-01-08 10:54:08 +02:00
Klaus Meinhardt 4cd859aa85 Allow referencing 'this' in parameters of functions in the constructor
Fixes: #29286
2019-01-07 22:09:27 +01:00
csigs 4a0bc59f77 LEGO: Merge pull request 29285
LEGO: Merge pull request 29285
2019-01-07 08:10:45 -08:00
csigs ec5224f114 LEGO: check in for master to temporary branch. 2019-01-07 16:10:20 +00:00
王文璐 d8aa46224d save work and fix lint 2019-01-07 11:04:00 +08:00
Kagami Sascha Rosylight 1d8a2ea38c Symbol.prototype.description hit stage 4 2019-01-06 11:42:55 +09:00
Sheetal Nandi 5135b83bf9 Merge pull request #29266 from Microsoft/jsxNamespace
Use the sourceFile to determine the jsxNamespace at the location for organizingImports
2019-01-04 14:43:48 -08:00
Sheetal Nandi 93249db692 Use the sourceFile to determine the jsxNamespace at the location for organizingImports
Fixes #28827
2019-01-04 14:12:04 -08:00
Wesley Wigham dcf825e3cd Add types entry to tslint build to prevent inclusion of unwanted types installed via user tests 2019-01-04 12:59:11 -08:00
Martin Probst 7a2b2cebbf Do not emit code for @extends tags in JS. (#29244)
When transpiling JavaScript, TS3.1+ emits `@extends` tags as code. E.g.

    /** @extends {SuperClass} */
    class SubClass {}

Causes an ES5 emit that references SuperClass:

    /**
    * @extends {SomeBase}
    */
    var SubClass = /** @class */ (function (_super) {
        __extends(SubClass, _super);
        function SubClass() {
            return _super !== null && _super.apply(this, arguments) || this;
        }
        return SubClass;
    }(SomeBase));

Note the literal references to `SomeBase`.

This appears to be an accidental effect of 0f55566cf4. It refactored
`getEffectiveBaseTypeNode` for type checking, but missed an instance
where it is also used for emit logic. This change fixes the problem by
specifically getting the heritage clauses directly off the AST.

Change-Id: I3128a757e5924e2528c61230a90ac13650852542
2019-01-04 08:13:14 -08:00
Sheetal Nandi b7d7d5f7b3 Merge pull request #29252 from Microsoft/tscWatchIsolatedModules
Do not cache semantic diagnostics with --isolated modules
2019-01-03 14:35:19 -08:00
Sheetal Nandi a633f95da7 Do not cache semantic diagnostics with --isolated modules
Fixes #28332
2019-01-03 14:07:25 -08:00
Sheetal Nandi bce9e2c11c Merge pull request #29250 from Microsoft/hasContextSensitiveReturnExpression
Fix function declaration without body to be checked as context sensitive
2019-01-03 14:06:13 -08:00
Klaus Meinhardt 2a2b573fa2 Merge branch 'master' of github.com:Microsoft/TypeScript into shebang-comments 2019-01-03 22:44:57 +01:00
Sheetal Nandi f4a6fb79da Replace ternary expression 2019-01-03 13:29:43 -08:00
Sheetal Nandi 8dff98dda0 Merge pull request #28992 from Microsoft/tscWatchExportUpdate
When removing the errors for the exports from the file, apart from re…moving transitive exports, remove the diagnostics of file that import these exports
2019-01-03 13:26:50 -08:00
Sheetal Nandi d8ee4116ef Fix function declaration without body to be checked as context sensitive
Fixes #29032
2019-01-03 12:46:39 -08:00
Sheetal Nandi c426fc6868 Merge branch 'master' into tscWatchExportUpdate 2019-01-03 11:35:54 -08:00
Sheetal Nandi d35ea02cc6 Merge pull request #29247 from ajafff/organizeimports-crash
Fix crash in organizeImports
2019-01-03 08:54:34 -08:00
Klaus Meinhardt e68f495b44 update baselines 2019-01-03 17:51:13 +01:00
Klaus Meinhardt 66314e1f85 Merge branch 'master' of github.com:Microsoft/TypeScript into rest-param-destructuring 2019-01-03 17:45:17 +01:00
Klaus Meinhardt 6eb9165553 Merge branch 'master' into shebang-comments 2019-01-03 17:38:25 +01:00
Klaus Meinhardt 6a9ad0e2eb Fix crash in organizeImports
Fixes: #29236
2019-01-03 16:20:46 +01:00
王文璐 34b1384152 add transformer for emit add property to default export 2019-01-03 11:19:02 +08:00
Sheetal Nandi b2f76e9dc8 Merge pull request #29240 from Microsoft/inferredProjectToExternalProject
The assert that cached value of config file existance is always correct, might not be true if file watcher is not invoked before creating configured project
2019-01-02 16:26:13 -08:00
Sheetal Nandi 24cc284d19 The assert that cached value of config file existance is always correct, might not be true if file watcher is not invoked before creating configured project
Fixes #29191
2019-01-02 15:42:12 -08:00
Benjamin Lichtman 799656a037 Merge pull request #29214 from uniqueiniquity/nestedAsyncCodeFix
Only provide suggestion for outermost async fix
2018-12-31 17:18:39 -08:00
Benjamin Lichtman 11585d29bc Merge pull request #29218 from uniqueiniquity/jsdocSpanForVarStatement
Jsdoc span for var statement
2018-12-31 16:27:34 -08:00
Benjamin Lichtman cb57f17aba Simplify approach 2018-12-31 16:25:26 -08:00
Benjamin Lichtman 28e68a6891 Fix spelling of convertible 2018-12-31 16:00:24 -08:00
Benjamin Lichtman 048d04684b use existing util functions 2018-12-31 15:56:54 -08:00
Benjamin Lichtman aebcb6df36 Merge pull request #29216 from uniqueiniquity/multilineArgumentSpans
Give appropriate outlining span for array and object literals as args in call expression
2018-12-31 15:18:07 -08:00
Benjamin Lichtman bb2f300191 Add test 2018-12-31 15:15:47 -08:00
Benjamin Lichtman 34970d8a69 give jsdoc outline span before func exp assigned to var 2018-12-31 15:10:22 -08:00
Benjamin Lichtman d3bcb82c6b Merge pull request #29215 from uniqueiniquity/classExpressionOutline
Outlining spans for class expressions
2018-12-31 15:03:09 -08:00
Benjamin Lichtman a266131928 Add test 2018-12-31 14:43:56 -08:00
Benjamin Lichtman 6c34520281 Use normal start for spans for args 2018-12-31 14:37:31 -08:00
Benjamin Lichtman adcb278272 Add test 2018-12-31 14:11:08 -08:00
Benjamin Lichtman b466336a3e Add class expression to set of nodes for outlining 2018-12-31 14:04:48 -08:00
Benjamin Lichtman 2dd6e20ef9 Only provide suggestion for outermost async fix 2018-12-31 11:50:40 -08:00
Daniel Rosenwasser 0dbb9760c0 Merge pull request #29147 from Kingwl/type_query_completions
fix typeof completions broken
2018-12-31 10:36:39 -08:00
Anders Hejlsberg beebda3574 Merge pull request #29110 from Microsoft/fixDiscriminantCheck
Fix discriminant property check
2018-12-30 17:46:01 -10:00
Anders Hejlsberg 8570a67572 Merge pull request #29121 from Microsoft/mappedTypeConstraints
Improve constraints for non-homomorphic mapped types
2018-12-30 17:44:41 -10:00
Anders Hejlsberg fd3af78b8b Merge pull request #29179 from Microsoft/typeParameterDefaultForwardReference
No self or forward references in type parameter defaults
2018-12-30 17:43:57 -10:00
Anders Hejlsberg 8e1403144d Merge pull request #29192 from Microsoft/initializerWidening
Fix initializer widening
2018-12-28 17:15:36 -10:00
Anders Hejlsberg 73b1dcb78f Accept new baselines 2018-12-28 09:38:24 -10:00
Anders Hejlsberg 7f4d1ac475 Add regression test 2018-12-28 09:38:19 -10:00