1
0
Fork 0
mirror of https://github.com/jashkenas/coffeescript.git synced 2022-11-09 12:23:24 -05:00
jashkenas--coffeescript/test
Geoffrey Booth 704924c3cd 2.0.0-beta3 (#4594)
* Don’t confuse the syntax highlighter

* Comment Assign::compilePatternMatch a bit

* Assignment expressions in conditionals are a bad practice

* Rename `wrapInBraces` to `wrapInParentheses`, to set the stage for future `wrapInBraces` that uses `{` and `wrapInBrackets` that uses `[`

* Correct comment

* object destructuring

* Allow custom position of the rest element.

* Output simple array destructuring assignments to ES2015

* Output simple object destructured assignments to ES2015

* Compile shorthand object properties to ES2015 shorthand properties

This dramatically improves the appearance of destructured imports.

* Don’t confuse the syntax highlighter

* Comment Assign::compilePatternMatch a bit

* Assignment expressions in conditionals are a bad practice

* Rename `wrapInBraces` to `wrapInParentheses`, to set the stage for future `wrapInBraces` that uses `{` and `wrapInBrackets` that uses `[`

* object destructuring

* Allow custom position of the rest element.

* rest element in object destructuring

* rest element in object destructuring

* fix string interpolation

* merging

* fixing splats in object literal

* Rest element in parameter destructuring

* merging with CS2

* merged with CS2

* Add support for the object spread initializer. https://github.com/tc39/proposal-object-rest-spread/blob/master/Spread.md

* Fix misspellings, trailing whitespace, other minor details

* merging with beta2

* refactor object spread properties

* small fix

* - Fixed object spread function parameters.
- Clean up "Assign" and moved all logic for object rest properties in single method (compileObjectDestruct).
- Add helper function "objectWithoutKeys" to the "UTILITIES" for use with object rest properties,
  e.g. {a, b, r...} = obj => {a, b} = obj, r = objectWithoutKeys(...)
- Clean up "Obj" and moved all logic for object spread properties in single method (compileSpread).
- Clean up "Code".
- Add method "hasSplat" to "Obj" and "Value" for checking if Obj contains the splat.
- Enable placing spread syntax triple dots on either right or left, per #85 (https://github.com/coffeescript6/discuss/issues/85)

* Fixed typos

* Remove unused code

* Removed dots (e.g. splat) on the left side from the grammar

* Initial release for deep spread properties, e.g. obj2 = {obj.b..., a: 1} or {obj[b][c]..., d: 7}
Tests need to be prepared!

* 1. Object literal spread properties

Object literals:
- obj = { {b:{c:{d:1}}}..., a:1 }

Parenthetical:
- obj = { ( body ), a:1 }
- obj = { ( body )..., a:1 }

Invocation:
- obj = { ( (args) -> ... )(params), a:1 }
- obj = { ( (args) -> ... )(params)..., a:1 }
- obj = { foo(), a:1 }
- obj = { foo()..., a:1 }

2. Refactor, cleanup & other optimizations.

* Merged with 2.0

* Cleanup

* Some more cleanup.

* Fixed error with freeVariable and object destructuring.

* Fixed errors with object spread properties.

* Improvements, fixed errors.

* Minor improvement.

* Minor improvements.

* Typo.

* Remove unnecessary whitespace.

* Remove unnecessary whitespace.

* Changed few "assertErrorFormat" tests since parentheses are now allowed in the Obj.

* Whitespace cleanup

* Comments cleanup

* fix destructured obj param declarations

* refine fix; add test

* Refactor function args ({a, b...})

* Additional tests for object destructuring in function argument.

* Minor improvement for object destructuring variable declaration.

* refactor function args ({a, b...}) and ({a, b...} = {}); Obj And Param cleanup

* fix comment

* Fix object destructuring variable declaration.

* more tests with default values

* fix typo

* Fixed default values in object destructuring.

* small fix

* Babel’s tests for object rest spread

* Style: spaces after colons in object declarations

* Cleanup comments

* Simplify Babel tests

* Fix comments

* Fix destructuring with splats in multiple objects

* Add test for default values in detsructuring assignment with splats

* Handle default values when assigning to object splats

* Rewrite traverseRest to fix handling of dynamic keys

* Fix double parens around destructuring with splats

* Update compileObjectDestruct comments

* Improve formatting of top-level destructures with splats and tidy parens

* Added a bigger destructuring-with-defaults test and fixed a bug

* Refactor destructuring grammar to allow additional forms

* Add a missing case to ObjSpreadExpr

* These tests shouldn’t run in the browser

* Fix test.html

* Fix docs scroll position getting screwed up by CodeMirror initialization

* Breaking change documentation about => (fixes #4593)

* Spread/rest syntax documentation

* Documentation about bound class methods

* 2.0.0-beta3 changelog

* Add note about ‘lib’

* Fix accidentally converting this to tabs

* Bump version to 2.0.0-beta3

* Update annotated source and test.html
2017-06-30 09:58:05 -07:00
..
importing renaming import test files to avoid risking the disfavor of .gitignore 2013-06-02 10:57:18 +04:00
support [CS2] Support for CSX - equivalent of JSX (#4551) 2017-06-06 23:33:46 -07:00
argument-parsing.coffee [CS2] Destructuring object spreads (#4493) 2017-06-29 22:57:42 -07:00
arrays.coffee Merge branch 'master' into 2 2016-11-10 22:51:39 -08:00
assignment.coffee [CS2] Destructuring object spreads (#4493) 2017-06-29 22:57:42 -07:00
async.coffee Update async test to use new super syntax 2017-02-04 17:05:18 -08:00
booleans.coffee
classes.coffee [CS2] Restore bound class methods via runtime check to avoid premature calling of bound method before binding (#4561) 2017-06-14 15:11:53 -07:00
cluster.coffee
comments.coffee [CS2] Support for CSX - equivalent of JSX (#4551) 2017-06-06 23:33:46 -07:00
compilation.coffee Merge branch 'master' into 2 2016-11-10 22:51:39 -08:00
comprehensions.coffee Allow @ values as indices in for expressions 2016-12-29 19:00:00 +00:00
control_flow.coffee Fix parenthesized conditions in if-else assignment (#4519) 2017-04-19 00:10:20 -07:00
csx.coffee [CS2] Support for CSX - equivalent of JSX (#4551) 2017-06-06 23:33:46 -07:00
error_messages.coffee [CS2] Destructuring object spreads (#4493) 2017-06-29 22:57:42 -07:00
eval.coffee Fix issue #3498 2015-01-05 15:40:04 -05:00
exception_handling.coffee #2900 -- parameter-less catch clause. 2013-04-12 17:50:45 +02:00
formatting.coffee 2.0.0-beta3 (#4594) 2017-06-30 09:58:05 -07:00
function_invocation.coffee [CS2] Fix non-bare get set when called with @ argument (#4525) 2017-04-23 11:23:36 -07:00
functions.coffee [CS2] Destructuring object spreads (#4493) 2017-06-29 22:57:42 -07:00
generators.coffee [CS2] Compile all super calls to ES2015 super (#4424) 2017-02-04 12:03:17 -08:00
helpers.coffee Replace last array helper with [..., last] = array 2015-02-07 21:50:41 +01:00
importing.coffee renaming import test files to avoid risking the disfavor of .gitignore 2013-06-02 10:57:18 +04:00
interpolation.coffee Fix #3795: Never generate invalid strings and regexes 2015-02-05 17:23:03 +01:00
javascript_literals.coffee Triple backticks to allow creation of JavaScript blocks (#4357) 2016-11-19 11:13:30 -08:00
literate.litcoffee [CS2] Literate CoffeeScript without dependencies (#4509) 2017-04-17 23:30:40 -07:00
literate_tabbed.litcoffee [CS2] Literate CoffeeScript without dependencies (#4509) 2017-04-17 23:30:40 -07:00
location.coffee Merge pull request #4444 from alangpierce/upstream-fix-heregex-end-location 2017-02-17 18:21:08 +01:00
modules.coffee [CS2] Support for CSX - equivalent of JSX (#4551) 2017-06-06 23:33:46 -07:00
numbers.coffee Treat Infinity and NaN as reserved words 2016-03-06 11:41:48 +01:00
objects.coffee Fix #4579: postfix for in object literals (#4581) 2017-06-20 21:50:50 -07:00
operators.coffee [CS2] Compile class constructors to ES2015 classes (#4354) 2017-01-12 21:55:30 -08:00
option_parser.coffee Remove hyphen in coffee-script 2017-02-12 17:00:05 -08:00
parser.coffee Properly update location data when setting a call to use new 2017-02-16 20:43:19 -08:00
ranges.coffee Add a for .. from .. loop for generators, see #4306, #3832 (#4355) 2016-11-07 23:40:01 -08:00
regexps.coffee [CS2] Support for CSX - equivalent of JSX (#4551) 2017-06-06 23:33:46 -07:00
repl.coffee Merge branch 'master' into 2 2017-04-17 19:52:34 -07:00
scope.coffee [CS2] Restore bound class methods via runtime check to avoid premature calling of bound method before binding (#4561) 2017-06-14 15:11:53 -07:00
slicing_and_splicing.coffee Fix #2953. Method calls on splice endpoints 2013-04-23 05:42:37 +02:00
soaks.coffee added descriptions to tests which only had Issue numbers 2015-02-23 16:39:05 -07:00
sourcemap.coffee Fix failing source map tests 2016-06-02 09:04:58 +02:00
strict.coffee merge master 2017-04-20 14:41:28 -05:00
strings.coffee [CS2] Support for CSX - equivalent of JSX (#4551) 2017-06-06 23:33:46 -07:00
tagged_template_literals.coffee Improve tests and comments 2016-12-03 10:16:41 -08:00