Commit Graph

32018 Commits

Author SHA1 Message Date
Sheetal Nandi 5aa7086b81 Use ts.indexOf instead of Array.indexOf method 2015-10-15 11:04:25 -07:00
Nathan Shively-Sanders 8eacd41ab0 Add tests and accept baselines 2015-10-15 09:52:31 -07:00
Nathan Shively-Sanders 6798bd576b Primitives are not assignable to any-type indexers
`string/numberIndexTypesRelatedTo` needs to prevent primitives from being
assignable to an indexer of type 'any'. However, these two functions take
an apparent type, which no longer has the primitive flag set. I thought of
three ways to provide this information:

1. Pass the original type into `string/numberIndexTypesRelatedTo` and
check its flag.
2. Record a boolean `isPrimitive` before converting to the apparent type,
and pass it to `string/numberIndexTypesRelatedTo`.
3. Create a helper function `isPrimitive` that takes the apparent type and
compares it to globalString/Number/Boolean/ESSymbolType.

I decided on (1) because it seems like the simplest and safest. But none
of the options are elegant. Please suggest improvements.
2015-10-15 09:45:38 -07:00
zhengbli 3e37b3158b Address code review at 5127 2015-10-14 21:36:35 -07:00
Zhengbo Li d703e09227 Merge pull request #5262 from zhengbli/Fix5127CR
Address code review from 5127
2015-10-14 18:20:06 -07:00
zhengbli b7c93c012f Address CR from 5127 2015-10-14 17:50:29 -07:00
Zhengbo Li 8864b06cbf Merge pull request #5127 from zhengbli/newAddDirectoryWatcher
Add directory watcher for tsserver and tsc
2015-10-14 17:43:10 -07:00
Zhengbo Li 2bf39a65d9 Merge pull request #5261 from zhengbli/i5015
Re-read file content upon closing
2015-10-14 17:41:54 -07:00
Ryan Cavanaugh 1a36fce4c2 JavaScript LS scaffolding + JS module inference 2015-10-14 17:36:03 -07:00
zhengbli fcfc25eeb0 Fix lint errors 2015-10-14 16:57:08 -07:00
zhengbli f91bee0324 Re-read file content upon closing 2015-10-14 16:50:31 -07:00
zhengbli c75499974e Fix rwcRunner 2015-10-14 16:31:27 -07:00
zhengbli 6013968b1f Address build errors 2015-10-14 16:25:27 -07:00
zhengbli 62664fdeda Add timer for batch processing directory changes 2015-10-14 16:09:41 -07:00
zhengbli def268cccf Fix issues with removing roots 2015-10-14 15:48:25 -07:00
zhengbli 002f0c066b CR feedback 2015-10-14 15:10:05 -07:00
Nathan Shively-Sanders c66bbd8cea Tests now correctly include a constructor 2015-10-14 12:43:56 -07:00
Mohamed Hegazy 21e30e0f59 Merge pull request #5235 from Microsoft/fixDecoratorDiagostics
Fix exception in compiler when type checking decorators with generics.
2015-10-14 12:29:08 -07:00
Nathan Shively-Sanders e964cb10ca Make constructor use merged parent symbol
Previously in getSignatureFromDeclaration, it just used the parent symbol
without checking whether it was merged.
2015-10-14 12:24:22 -07:00
Nathan Shively-Sanders 12b7a998e9 Add test case 2015-10-14 12:23:37 -07:00
Sheetal Nandi 81763543f3 Fix the duplicate function implementation error that depended on order of files 2015-10-14 12:00:43 -07:00
Mohamed Hegazy 5234bf698c Merge pull request #5033 from Microsoft/dirkb/fix_5032
Fixed #5032: tsserver: Format on type broken
2015-10-14 09:49:50 -07:00
Vladimir Matveev 124447763b Merge pull request #5233 from Microsoft/relaxedUseBeforeDef
allow forward references to block scoped variables from functions
2015-10-13 14:19:01 -07:00
Mohamed Hegazy 99d448a167 Merge pull request #5231 from Microsoft/removeExperimentalAsyncFunctions
Remove experimental async functions
2015-10-13 14:17:36 -07:00
Ryan Cavanaugh b2d666c489 Merge pull request #5184 from RyanCavanaugh/fix5096
Don't issue completion in JSX text
2015-10-13 13:27:39 -07:00
Vladimir Matveev 0465f1b0bb revert enum related changes 2015-10-13 13:18:58 -07:00
Ryan Cavanaugh 6bbfe56dca Use memberListCount 2015-10-13 13:16:44 -07:00
Vladimir Matveev 55327781c2 suppress reachability errors in remaining tests 2015-10-13 13:06:43 -07:00
Vladimir Matveev 238e1c6f4b partially suppress reachability errors in tests 2015-10-13 11:17:10 -07:00
Vladimir Matveev bc02341e99 addressed PR feedback, updated tests to suppress reachability errors where they are not needed 2015-10-13 10:58:55 -07:00
Vladimir Matveev 17716fb540 accepted baselines 2015-10-13 09:06:58 -07:00
Vladimir Matveev 48b24343b1 use isBlockScopedNameDeclaredBeforeUse for block scoped variables and enums 2015-10-13 00:07:36 -07:00
Vladimir Matveev 938dd747c6 Merge branch 'master' into reachabilityChecks 2015-10-12 22:33:25 -07:00
Ron Buckton 0fa89ad99c Fixes #5104. 2015-10-12 17:38:55 -07:00
Vladimir Matveev eb3b91cf1b addressed PR feedback 2015-10-12 17:24:39 -07:00
Wesley Wigham c4a15d9a3b Merge pull request #5067 from Microsoft/travis-node-4
CI Against Node 4
2015-10-12 16:58:36 -07:00
Yui 77eaf04386 Merge pull request #4914 from Microsoft/exponentiation
[ES7] Exponentiation
2015-10-12 16:37:45 -07:00
Sheetal Nandi 11b270f6ca Add testcase - generating declaration file results in more errors in ts file 2015-10-12 16:27:11 -07:00
Vladimir Matveev f952873ef1 allow forward references to block scoped variables from functions 2015-10-12 16:18:37 -07:00
Vladimir Matveev c8ba16644b Merge pull request #4911 from Microsoft/liftDtsOnlyRestriction
extend the list of extensions for module file names in node_modules f…
2015-10-12 14:48:47 -07:00
Sheetal Nandi 9f96f47a4f Added scenario when duplicate function implementation is reported 2015-10-12 14:47:22 -07:00
Sheetal Nandi d4d6e48ea5 Adding test case for scenario in which error reported depends on order of files 2015-10-12 14:39:10 -07:00
Nathan Shively-Sanders 92c2d48465 Lint: remove trailing whitespace 2015-10-12 14:37:10 -07:00
Yui T 90258794a6 Address PR feedback 2015-10-12 14:32:48 -07:00
Sheetal Nandi b38a81bc73 Emit enabled for JS files 2015-10-12 14:31:44 -07:00
Mohamed Hegazy e9bed76baa Remove --experimentalAsyncFunctions from tests 2015-10-12 14:27:58 -07:00
Mohamed Hegazy 92f1b48cc8 Remove --experimentalAsyncFunctions 2015-10-12 14:27:33 -07:00
Nathan Shively-Sanders 3a55c849c7 Assert that ambient classes merge with interfaces
Specifically, overloads are recognised as having the same export/ambient
flags when merging the two.
2015-10-12 14:26:45 -07:00
Nathan Shively-Sanders d6ae55708d Do not mark class members as ambient or export.
Even members of ambient classes. These flags have no useful semantics
there, and it prevents ambient classes from merging properly with
interfaces.
2015-10-12 14:25:39 -07:00
Nathan Shively-Sanders 8a051343ff Merge pull request #5169 from Microsoft/fix-simple-uses-of-polymorphic-this-in-services
Fix simple uses of polymorphic this in services
2015-10-12 13:54:50 -07:00