1469 Commits

Author SHA1 Message Date
Wesley Wigham
dd933f4413
Fix get symbol at location to behave correctly for parameter assignments and jsx attributes (#20706)
* Fix get symbol at location to behave correctly got parameter assignments and jsx attributes

* Handle all those edge cases that weren;t explicitly handled

* Fix part of bug WRT getTypeAtLocation and for loops

* Baseline corrections pursuant to #20710

* Restore jsdoc tag interpretation

* Clean up some code, revert fourslash tests

* Cleanup types used by PR feedback
2017-12-15 15:50:22 -08:00
Andy
484758a3d3
Handle ! following a keyword in isClassMemberStart (#20617)
* Handle `!` following a keyword in isClassMemberStart

* Fix test
2017-12-11 09:45:36 -08:00
Anders Hejlsberg
b4b9edc04c Make sure 'async' isn't treated as a parameter modifier 2017-11-21 18:39:01 -08:00
Anders Hejlsberg
9abb72d920
Merge pull request #20166 from Microsoft/definiteAssignmentAssertions
Definite assignment assertions
2017-11-21 06:27:56 -08:00
Wesley Wigham
a551c4cd64
Allow curly around @type jsdoc to be optional (#20074)
* Allow curly around `@type` jsdoc to be optional

* Incorporate restructuring from @andy-ms
2017-11-20 16:10:50 -08:00
Anders Hejlsberg
272076391b Allow '!' only on variable declarations within variable statements 2017-11-20 09:31:11 -08:00
Anders Hejlsberg
1624e1bc1a Definite assignment assertion '!' on variable and property declarations 2017-11-19 16:48:43 -08:00
Anders Hejlsberg
b6f96052d8
Merge pull request #19976 from Microsoft/optimizeParser
Optimize parsing
2017-11-16 10:19:10 -08:00
Ron Buckton
a21a129abb Merge branch 'master' into dynamicNames 2017-11-15 15:24:05 -08:00
Andy
4b96edf72f
Treat ... in jsdoc type as creating a synthetic rest parameter -- not as an array type (#19483)
* Treat `...` in jsdoc type as creating a synthetic rest parameter -- not as an array type

* Change type parsing so `...T[]` parses as `...(T[])` and not `(...T)[]`

* Replace the last parameter with ...args, and make access to it potentially undefined

* Code review
2017-11-15 13:04:08 -08:00
Anders Hejlsberg
ee851784a6 Remove dead code that didn't get removed in #19979 2017-11-14 14:03:56 -08:00
Anders Hejlsberg
dbeb68274f Merge branch 'master' into optimizeParser
# Conflicts:
#	src/compiler/parser.ts
2017-11-14 09:22:18 -08:00
Andy
7e8851e65b
Always require '=' before parsing an initializer (#19979)
* Always require '=' before parsing an initializer

* Fix fourslash tests
2017-11-14 07:15:59 -08:00
Anders Hejlsberg
969f06462d Improve lookahead for arrow functions to reduce speculative parsing 2017-11-13 15:12:46 -08:00
Ron Buckton
804c7d3690 Merge branch 'master' into dynamicNames 2017-11-13 13:24:20 -08:00
Andy
9d8a854ea2
Revert "Break out of speculative parsing on bad parameter initializer (#19158)" (#19975)
This reverts commit e7df83263df9433d2b27a2b86e9d198fca68bd92.
2017-11-13 13:22:09 -08:00
Anders Hejlsberg
3411318e6b Use TokenFlags.PrecedingJSDocComment to guide JSDoc comment processing 2017-11-13 09:51:56 -08:00
Andy
e7df83263d
Break out of speculative parsing on bad parameter initializer (#19158)
* Break out of speculative parsing on bad parameter initializer

* Remove uses of 'finally'

* give up -> stop

* Do without exceptions

* Remove `resetAfterSpeculation`

* Use Fail and FailList objects

* Remove `inSpeculation` parameter to parseDelimitedList

* Don't use `createNodeArray`, it's not always in scope

* Move Fail and FailList inside initializeState

* More code review

* More code review
2017-11-13 09:18:36 -08:00
Anders Hejlsberg
ddf0df9cbb Introduce TokenFlags enum 2017-11-12 09:11:09 -08:00
Ron Buckton
3f248ecfe1
Merge pull request #19452 from Microsoft/compareStrings
Clean up outdated string comparison logic
2017-11-06 18:48:15 -08:00
Ron Buckton
33e09f9a9d Merge branch 'master' into dynamicNames 2017-11-06 12:05:25 -08:00
Andy
0a7b7e07ee
Apply 'variable-name' tslint rule (#19743) 2017-11-06 09:23:47 -08:00
Ron Buckton
31c3d444f1 Merge branch 'master' into compareStrings 2017-11-03 23:01:51 -07:00
Ron Buckton
208dfa6b01 Merge branch 'master' into dynamicNames 2017-11-03 22:10:28 -07:00
Andy
cc2a2a79b5
Use NodeFlags to detect nodes in ambient contexts instead of climbing ancestors (#17831)
* Use NodeFlags to detect nodes in ambient contexts instead of climbing ancestors

* Set context flags on tokens

* Remove 'isDeclarationFile' parameter to 'initializeState' and move to 'parseSourceFileWorker'

* Changes based on code review

* Update API baselines
2017-11-03 08:08:48 -07:00
uniqueiniquity
3ebb2e8a34 Merge branch 'master' into jsxFragment 2017-10-31 10:53:57 -07:00
Ron Buckton
26ca98c820 Merge branch 'master' into dynamicNames 2017-10-30 18:02:53 -07:00
Ron Buckton
44117e19ea Reduce noise in PR, minor cleanup 2017-10-26 17:57:54 -07:00
Ron Buckton
c0ed26e605 Simplify comparers 2017-10-25 17:46:39 -07:00
Ron Buckton
130c407708 More control over which collator to use in each situation 2017-10-25 16:30:19 -07:00
Ron Buckton
dee77ced7c Added 'equateStrings' for string equality comparisons (rather than sorting) 2017-10-24 16:14:49 -07:00
uniqueiniquity
fb058868de Respond to CR 2017-10-24 13:24:11 -07:00
Andy
159a0a2197 Use NodeFlags to detect nodes inside with statements instead of climbing ancestors (#17721)
* Use NodeFlags to detect nodes inside with statements instead of climbing ancestors

* Add to ContextFlags
2017-10-23 13:38:50 -07:00
Ron Buckton
51929acb89 Merge branch 'master' into dynamicNames 2017-10-21 00:36:52 -07:00
uniqueiniquity
75665294a9 Respond to CR 2017-10-17 13:39:16 -07:00
uniqueiniquity
abb3f58db2 Add support for JSX fragment syntax 2017-10-17 09:38:09 -07:00
Arthur Ozga
1db762356e Merge pull request #18706 from aozgaa/dev/aozgaa/JsDocExtendsSupport
support @extends in jsdoc
2017-10-09 15:08:58 -07:00
Andy
8a55baf9a3 In @typedef tag, handle property with no type (#19013) 2017-10-09 09:58:02 -07:00
Arthur Ozga
5ea3ca4ef9 Merge branch 'master' into dev/aozgaa/JsDocExtendsSupport 2017-10-06 14:25:31 -07:00
Ron Buckton
ee23f93275 Switch to 'unique symbol' 2017-10-04 19:34:29 -07:00
Ron Buckton
43c151a9df Merge branch 'master' into dynamicNames 2017-10-04 14:57:24 -07:00
Andy
46e135b098 Fix parsing of qualified name in @augments (#18914) 2017-10-03 13:47:01 -07:00
Ron Buckton
7ab451bfe7 Merge branch 'master' into dynamicNames 2017-10-03 11:00:30 -07:00
Nathan Shively-Sanders
4d8663c378 Merge pull request #18117 from Microsoft/jsdoc-dotdotdot-binds-tighter-than-postfix
Jsdoc ... binds tighter than postfix ?!
2017-10-03 08:45:26 -07:00
Ron Buckton
6f05e43b55 Merge branch 'master' into dynamicNames 2017-10-02 19:08:09 -07:00
Andy
3a2c723a69 Allow parsing a qualified type name containing a reserved word (#18888) 2017-10-02 17:04:28 -07:00
Ron Buckton
fb3168d46f Merge branch 'master' into dynamicNames 2017-10-02 11:40:28 -07:00
Andy
1a2de721b5 Fixes to @augments handling (#18775)
* Fixes to @augments handling

* Renames and diagnostic changes

* Add test for < > characters

* Use more specific return type
2017-09-28 12:34:54 -07:00
Andy
024b1fd913 Make it a parse error for an @augments jsdoc tag to not include a type (#18745) 2017-09-25 09:26:59 -07:00
Arthur Ozga
b21c46b9b5 support @extends in jsdoc 2017-09-22 16:21:31 -07:00