Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Feb 19, 2018. It is now read-only.
/discussPublic archive

Commit95608ef

Browse files
committed
Core classes PR has been merged
1 parentdf5385e commit95608ef

File tree

1 file changed

+16
-26
lines changed

1 file changed

+16
-26
lines changed

‎Features.md

Lines changed: 16 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@ These features affect interopability and should take priority over all other fea
1414
1515
[This has been merged](https://github.com/jashkenas/coffeescript/pull/4300) and released as part of CoffeeScript 1.11.
1616

17-
###Classes: Extend ES Classes[(#22)](https://github.com/coffeescript6/discuss/issues/22)
17+
###~~Classes: Extend ES Classes, Idiomatic Methods[(#22)](https://github.com/coffeescript6/discuss/issues/22)~~
1818

1919
>CoffeeScript 2 only
2020
21-
As part of CoffeeScript 2, we will update CoffeeScript’s`class` to output an ES`class` keyword, so that ES2015 classes can be extended and so that CoffeeScript classes can be extended in ES. We will also revise CoffeeScript’s class output to handle`this` in a constructor before calling`super`, and any other changes we need to make to adhere to ES syntax.Thisis the “must-do” part of classes; improving the output by making it more idiomatic (not using`prototype` or`__super__`, etc.) is a separate item under Medium Priority below. This is in progress at[jashkenas/coffeescript#4354](https://github.com/jashkenas/coffeescript/pull/4354).
21+
[Thishas been merged](https://github.com/jashkenas/coffeescript/pull/4354) into the`2` branch.
2222

2323
###~~Tagged template literals[(#28)](https://github.com/coffeescript6/discuss/issues/28)~~
2424

@@ -30,11 +30,17 @@ As part of CoffeeScript 2, we will update CoffeeScript’s `class` to output an
3030

3131
These features aren’t required for CoffeeScript to be used in any project, but there’s great desire in the community for these to be added.
3232

33-
###Classes: IdiomaticES Output[(#22)](https://github.com/coffeescript6/discuss/issues/22)
33+
###Classes: Idiomatic`super`[(#22)](https://github.com/coffeescript6/discuss/issues/22)
3434

3535
>CoffeeScript 2 only
3636
37-
Building off of the essential class-related items in Top Priority, this item is for the nonessential items like removing our dependence on`prototype` and`__super__`, and generally cleaning up our output and making it more idiomatic. This is where we would also add support for getters and setters[(#17)](https://github.com/coffeescript6/discuss/issues/17) and the`static` keyword. This is in progress at[jashkenas/coffeescript#4354](https://github.com/jashkenas/coffeescript/pull/4354).
37+
CoffeeScript’s`super` should always be compiled to ES2015’s`super`. This is in progress at[jashkenas/coffeescript#4424](https://github.com/jashkenas/coffeescript/pull/4424).
38+
39+
###Classes:`static`,`get` and`set` keywords[(#17)](https://github.com/coffeescript6/discuss/issues/17)
40+
41+
>CoffeeScript 2 only
42+
43+
Classes should support getters and setters[(#17)](https://github.com/coffeescript6/discuss/issues/17) and the`static` keyword.
3844

3945
###~~`async`/`await`[(#10)](https://github.com/coffeescript6/discuss/issues/10)~~
4046

@@ -52,6 +58,10 @@ Building off of the essential class-related items in Top Priority, this item is
5258

5359
These are nice-to-have features that should be implemented as time permits, probably only in the “new” compiler if one gets created. Any change that causes ES2015 output and isn’t opt-in needs to either be enabled by a flag or only in the new, ESNext-outputting compiler.
5460

61+
###Destructuring assignment[(#18)](https://github.com/coffeescript6/discuss/issues/18)
62+
63+
>CoffeeScript 2 only
64+
5565
###~~Template literals[(#41)](https://github.com/coffeescript6/discuss/issues/41)~~
5666

5767
>CoffeeScript 2 only
@@ -64,40 +74,20 @@ These are nice-to-have features that should be implemented as time permits, prob
6474
6575
[This has been merged](https://github.com/jashkenas/coffeescript/pull/4311) into the`2` branch.
6676

67-
###Destructuring assignment[(#18)](https://github.com/coffeescript6/discuss/issues/18)
68-
69-
>CoffeeScript 2 only
70-
7177
###~~`for … of`[(#11)](https://github.com/coffeescript6/discuss/issues/11)~~
7278

7379
>CoffeeScript 1.x and 2
7480
7581
[This is has been merged](https://github.com/jashkenas/coffeescript/pull/4306) and released as part of CoffeeScript 1.12.
7682

77-
##Uncertain
83+
##No Action
7884

79-
These are featureswe’re not sure we will implement, in any version of CoffeeScript:
85+
These areotherfeaturesthat have been discussed, but the consensus at the moment is that no action should be taken to implement them.
8086

8187
###Block assignment`let` and`const` assignment operators[(#31)](https://github.com/coffeescript6/discuss/issues/31) or[(#35)](https://github.com/coffeescript6/discuss/issues/35)
8288

83-
>CoffeeScript 2 only
84-
85-
For whatever reason,`let` and`const` are among the most popular features introduced by ES2015. Awaiting consensus on which of these two proposals we want to adopt, if either. Per[#1](https://github.com/coffeescript6/discuss/issues/1), there seems to be consensus that we want some way to support`const` and probably`let` in CoffeeScript.
86-
87-
If we support`const` only,[(#31)](https://github.com/coffeescript6/discuss/issues/31), a new`:=` operator would be added, e.g.`a := 1` would become`const a = 1;`. This would give us the “throw an error if a`const`-declared variable is reassigned” feature of`const`, plus block-scoping but only for`const`s.
88-
89-
If we support`let` and`const`,[(#35)](https://github.com/coffeescript6/discuss/issues/35), which would be necessary if we want to gain the block-scope aspects of the new`let` and`const` keywords, we would need two new operators:`:=` for`let` and`:==` for`const`. The`:=`-defined variables would get their`let` declarations grouped together at the tops of their blocks.
90-
9189
###Inferred`let` assignment[(#1)](https://github.com/coffeescript6/discuss/issues/1)
9290

93-
>CoffeeScript 2 only
94-
95-
When a variable isn’t declared using a new operator that produces`const` (see above), CoffeeScript should automatically declare it with`let` whenever possible.
96-
97-
##No Action
98-
99-
These are other features that have been discussed, but the consensus at the moment is that no action should be taken to implement them.
100-
10191
###Decorators[(#9)](https://github.com/coffeescript6/discuss/issues/9)
10292

10393
###Type annotations[(#12)](https://github.com/coffeescript6/discuss/issues/12)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp