Commit Graph
125 Commits
Author SHA1 Message Date
Daniel Rosenwasser c5349dc95f Accept object literal commas in ES3, preserve in ES5. 2014-07-29 16:25:10 -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
Anders Hejlsberg fc0004749f Merge pull request #264 from Microsoft/errorOnHiddenModuleImport
Error when importing shadowed internal module.
2014-07-27 18:09:04 -07:00
Anders Hejlsberg 3da5f1ef6f Error when importing shadowed internal module.
Fixes #73.
2014-07-26 08:13:52 -07:00
Vladimir Matveev e4256d827d Merge pull request #252 from Microsoft/array_symbol_links
Use symbol links to access global array type
2014-07-25 17:12:14 -07:00
Jason Freeman 9e039f53b5 Merge pull request #259 from Microsoft/canParseSemicolon
Remove isSemicolon
2014-07-25 17:09:08 -07:00
Vladimir Matveev a2210184be comments updated 2014-07-25 17:08:35 -07:00
Vladimir Matveev 6fe8acb103 added comments 2014-07-25 16:49:35 -07:00
Vladimir Matveev 956b6398e0 localize special case (globalArrayType === undefined) in getTypeFromArrayTypeNode 2014-07-25 16:42:09 -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
Jason Freeman 4ee714f4e7 Merge branch 'master' into forInError 2014-07-25 15:10:34 -07:00
Jason Freeman 34f01f262d Merge pull request #257 from Microsoft/untyped
Fix up comment about in checkCallExpression
2014-07-25 14:03:02 -07:00
Jason Freeman 936863c299 Update error message to be more consistent with others 2014-07-25 14:01:50 -07:00
Jason Freeman aa40dc59b1 Fix up comment about bug #236 in checkCallExpression 2014-07-25 13:39:11 -07:00
Jason Freeman b2abab2f93 Improve the error in a 'for in' statement 2014-07-25 12:38:36 -07:00
Vladimir Matveev 442ad4b032 use symbol links to access global array type 2014-07-25 12:06:18 -07:00
Anders Hejlsberg 299f1c3390 Properly set exit code for process.
Supercedes #246.
Includes provisions for buggy behavior of WScript.Quit.
2014-07-25 11:01:09 -07:00
Anders Hejlsberg f991054691 Merge branch 'master' into argumentTypeErrors 2014-07-25 06:40:51 -07:00
Anders Hejlsberg 511402cd84 Addressing CR feedback. 2014-07-24 19:39:50 -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
Anders Hejlsberg a515b199b7 Better error messages in function calls.
Fixes #93.
This is an evolution of #220.
2014-07-24 17:00:03 -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
Jason Freeman 29284cb1b9 Merge branch 'master' into errorOnWithStatement 2014-07-23 11:53:58 -07:00
Jason Freeman ed3d740df4 Merge branch 'master' into errorOnWithStatement 2014-07-23 11:52:40 -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 0e10fc76b8 Removed parentheses around arrow function parameters.
As per feedback in pull request #147.
2014-07-22 17:08:12 -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
Daniel Rosenwasser c8fc26a20a Merge pull request #147 from Microsoft/noReturnExpression
Complain when a non-void function lacks a return expresson.
2014-07-22 13:46:54 -07:00
Jason Freeman f79cba2225 Type check the expression of the 'with' statement 2014-07-22 13:37:37 -07:00
Anders Hejlsberg c5db1614f6 Aligning index signature type inference with assignability rules.
Type inference now supports inferring from string index signatures to numeric index signatures.
Fixes #167.
2014-07-22 11:53:06 -07:00
Anders Hejlsberg 13d64adeb9 Merge pull request #175 from Microsoft/contextualSignatureInstantiation
Added contextual signature instantiation during type inference.
2014-07-22 10:57:01 -07:00
Anders Hejlsberg d85df9e9fa Addressing CR feedback.
Adding comment to explain source type instantiation.
Adding a test case.
2014-07-22 10:54:20 -07:00