Commit Graph
75 Commits
Author SHA1 Message Date
Cyrus Najmabadi a1b7c4f54c Revert "Merge pull request #444 from Microsoft/newCompilerLS"
This reverts commit ae5f4c2617, reversing
changes made to 2f963743c4.
2014-08-14 17:37:45 -07:00
Cyrus Najmabadi 474cf0d575 Port over changes to the ScriptSnapshot API from the languageService-v2 branch. 2014-08-12 17:12:23 -07:00
Jason Freeman cc7ca33eef Simplify checking for octal literals in parser 2014-08-07 12:49:52 -07:00
Jason Freeman 92f7c98adb Merge branch 'master' into octal 2014-08-07 12:11:13 -07:00
Jason Freeman b1f71e6504 Address feedback 2014-08-07 12:08:31 -07:00
Jason Freeman 72cf78f681 Error on octal literals in ES5 and strict mode 2014-08-06 18:10:16 -07:00
Mohamed Hegazy 63b835a7a9 Remove ByteOrderMark 2014-08-06 11:13:49 -07:00
Anders Hejlsberg a2a6b8a410 Support extensionless <reference> comments.
Fixes #344.
2014-08-05 14:32:53 -07:00
Daniel Rosenwasser 40f6ed0b65 Merge pull request #262 from Microsoft/trylessCatchesFinallyParseNicely
Improved errors for 'catch'/'finally' blocks missing 'try' statements
2014-08-04 15:56:20 -07:00
Mohamed Hegazy 3c0fd5324c Merge branch 'master' into getDefinition 2014-08-04 13:43:14 -07:00
Dick van den Brink c9c8748152 Code style: Missing semicolons 2014-08-04 22:32:32 +02:00
Mohamed Hegazy aa75de9c70 Consolidate Document and SoruceFile 2014-08-04 12:00:37 -07:00
Daniel Rosenwasser 9a89147587 Merge pull request #324 from Microsoft/watcherIardlyKnowEr
Support the '--watch' compiler flag.
2014-08-02 17:52:02 -07:00
Mohamed Hegazy 61436368b5 Merge branch 'master' into ls 2014-07-31 18:43:53 -07:00
Daniel Rosenwasser 617910b3d4 Support the '--watch' compiler flag. 2014-07-31 14:57:54 -07:00
Daniel Rosenwasser add65f1f29 Merge branch 'master' into trylessCatchesFinallyParseNicely
Conflicts:
	src/compiler/diagnosticMessages.json
2014-07-31 14:49:14 -07:00
Daniel Rosenwasser ef5ae6e969 Merge pull request #273 from Microsoft/es3HatesTrailingCommas
No longer emit trailing comma on object literals for ES3.
2014-07-29 16:31:17 -07:00
Daniel Rosenwasser c5349dc95f Accept object literal commas in ES3, preserve in ES5. 2014-07-29 16:25:10 -07:00
Mohamed Hegazy 346809ba2b wire in getCompletions 2014-07-29 12:10:21 -07:00
Mohamed Hegazy 8eda35afa0 Ensure SimpleArrowFunctionExpression has a NodeArray as its paramter as ForEachChild expexts that 2014-07-29 12:07:47 -07:00
Mohamed Hegazy 2ed3de1c28 push newline to compilerhost instead of using sys directelly. This allows the language service to set it, as sys is not defined in language service scenarios 2014-07-29 12:06:43 -07:00
Daniel Rosenwasser fce3bdd171 Merge pull request #256 from Microsoft/ambientAccessorErrors
Gracefully handle accessor declarations in ambient classes.
2014-07-29 11:46:32 -07:00
Daniel Rosenwasser fe4c738b01 No longer emit trailing comma on object literals.
This was done because trailing commas in object literals are not accepted by ES3.

Fixes #271.
2014-07-28 11:37:36 -07:00
Daniel Rosenwasser 79735b4431 Simplified error recovery by just using 'parseTryStatement'. 2014-07-26 21:23:50 -07:00
Daniel Rosenwasser efb6db8757 Gracefully handle 'catch' and 'finally' blocks without a preceding 'try' block.
Fixes #216.

As a note of this fix, when a 'catch' block is followed by a 'finally' block, only the 'catch' keyword gets an error reported on it.
2014-07-25 18:10:27 -07:00
Jason Freeman 9e039f53b5 Merge pull request #259 from Microsoft/canParseSemicolon
Remove isSemicolon
2014-07-25 17:09:08 -07:00
Jason Freeman 478fadfe3d Disallow modifiers on export assignments (fix #164) 2014-07-25 16:39:24 -07:00
Jason Freeman 61731eefdf Remove isSemicolon (fix #200) 2014-07-25 16:17:30 -07:00
Daniel Rosenwasser fc80c300a0 Gracefully handle accessor declarations in ambient classes. 2014-07-25 13:21:55 -07:00
Daniel Rosenwasser c625cd9259 Merge pull request #203 from Microsoft/arrowLookAhead
Improved lookahead for arrow functions.
2014-07-24 18:41:34 -07:00
Daniel Rosenwasser b0c59e7c37 Merge branch 'master' into arrowLookAhead 2014-07-24 18:17:30 -07:00
Daniel Rosenwasser b76c13cfd5 Addressed code review feedback. 2014-07-24 18:05:05 -07:00
Jason Freeman 86007cc137 Merge branch 'master' into labelledStatements
Conflicts:
	src/compiler/diagnosticInformationMap.generated.ts
	src/compiler/diagnosticMessages.json
	src/compiler/parser.ts
2014-07-24 17:48:11 -07:00
Jason Freeman a19698c37d Address feedback 2014-07-24 17:38:37 -07:00
Vladimir Matveev 48ff93963b added comments 2014-07-24 13:02:37 -07:00
Vladimir Matveev 6572c826a1 update check for object literal properties according to ECMA spec 2014-07-24 13:02:31 -07:00
Vladimir Matveev 9112a0e2e2 enabled strict mode 2014-07-24 13:01:25 -07:00
Jason Freeman fde2591d6f Add interface LabelledStatementInfo 2014-07-24 12:56:03 -07:00
Jason Freeman 742637bec9 Add tracking for labelled statements, and errors on labelled jumps 2014-07-24 12:36:10 -07:00
Jason Freeman b9971f2876 Add consumption points and error reporting for labelled statement errors 2014-07-23 16:48:18 -07:00
Anders Hejlsberg e742694b1a Merge pull request #199 from Microsoft/reservedWordsInTypeQueries
Allow reserved words in type queries.
2014-07-23 15:52:09 -07:00
Jason Freeman 1a66243d4f Remove inModuleBody 2014-07-23 14:09:17 -07:00
Daniel Rosenwasser 57d7cf54c6 Improved "certainty" when parsing arrow-function-lookin' expressions. 2014-07-23 13:31:24 -07:00
Jason Freeman 76804eb1f9 Add errors for break and continue statements 2014-07-23 12:07:46 -07:00
Jason Freeman e2617750b1 Track control flow contexts in the parser, and give errors for break, continue, return 2014-07-23 11:57:34 -07:00
Daniel Rosenwasser 5fc2792297 Covered more cases for arrow functions omitting arrows.
Specifically where we have a full signature followed by an open curly brace.
2014-07-23 11:49:51 -07:00
Vladimir Matveev d10f2e713e do not propagate property name as name for function expression 2014-07-23 11:48:29 -07:00
Anders Hejlsberg 1c594d06a2 Addressing CR feedback.
Making allowReservedWords parameter of parseEntityName non-optional.
2014-07-23 10:17:39 -07:00
Daniel Rosenwasser 5b6bb5b649 Improved lookahead for arrow functions.
Fixes issue #34.

Specifically:
    * We no longer automatically assume "()" is a function expression. It must be followed by an arrow, colon, or curly brace.
    * If an arrow is missing following a signature, but a curly brace is present, we assume the user forgot the arrow and try to parse the body anyway.
2014-07-22 17:01:10 -07:00
Anders Hejlsberg 0550b93635 Allow reserved words in type queries.
Fixes #181.
2014-07-22 15:11:24 -07:00