Permalink
...
Comparing changes
Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also .
Open a pull request
Create a new pull request by comparing changes across two branches. If you need to, you can also .
Choose a Base Repository
jashkenas/coffeescript
CDR2003/coffee-script-lua
CreamCoderz/coffee-script
Crylock/coffee-script
GeoffreyBooth/coffeescript
Gregg/coffee-script
JulianBirch/coffee-script-1
JustinTulloss/coffee-script
MichaelBlume/coffee-script
NightMigera/coffeescript
PandaWood/coffee-script
ProximaMonkey/coffee-script
Remcoman/coffee-script
RicardoSaracino/coffee-script
SE7ENSKY/matescript
STRd6/coffee-script
ShawnFumo/coffee-script
StanAngeloff/coffee-script
Xepo/coffee-script
abi/coffee-script
agnoster/coffee-script
ahjohannessen/coffee-script
akiellor/coffee-script
alanning/coffee-script
allanberger/coffee-script
almost/coffee-script
alubbe/coffee-script
andrehjr/coffee-script
andrewschaaf/coffee-script
andreypopp/coffee-script
apanda/coffee-script
baoshitang/coffee-script
barberboy/coffee-script
benatkin/coffee-script
benbria/coffee-script
benekastah/coffee-script
bjouhier/coffee-script
blahutka/coffee-script
blossom/coffee-script
bolinfest/coffee-script
breckinloggins/coffee-script
carmelyne/contracts.coffee
chajath/coffee-script
charles-cai/coffee-script
charliesome/coffee-script
chetan51/coffee-script
chip/coffee-script
codelahoma/coffee-script
coffee-js/coffee-script
coffee-void/coffeescript
collin/coffee-script
danemorgridge/coffee-script
daveclarke/coffee-script
daveyoon/coffee-script
dbrans/coffee-script
deadprogram/coffee-script
devongovett/coffee-script
dget/coffee-script
disnet/contracts.coffee
dmohl/coffee-script
dohse/coffee-script
dqminh/coffee-script
drewlesueur/coffee-script
eventualbuddha/coffee-script
evilpie/coffee-script
excellentdrums/coffee-script
fitzgen/coffee-script
fizx/coffee-script
geraldalewis/coffee-script
germanocaldeira/coffee-script
gfodor/coffee-script
ghuntley/coffee-script
goodwink/coffee-script
gxela/coffee-script
hayeah/coffee-script
hbt/coffee-script
helixbass/copheescript
hleumas/coffee-script
holtwick/moccacino
hugs/coffee-script
ianthehenry/protoscript
ich/caffeine
janlelis/angular-coffee-script
jaredwy/coffee-script
jasonyandell/coffee-script
jawj/coffee-script
jbca/coffeescript
jiangmiao/toffee-script
jlstr/coffee-script
joelturnbull/coffee-script
johnsang/coffee-script
joliss/coffee-script
jondistad/coffee-script
joshprice/coffee-script
jstrachan/coffee-script
jugglinmike/irene-script
juilyoon/coffee-script
keichii/coffee-script
keithnorm/coffee-script
kewinwang/coffee-script
khaled/coffee-script
leeight/coffee-script
level1/coffee-script
lfendy/coffee-script
loganfsmyth/coffee-script
loopinfinito/coffeescript.com.br
lorensr/coffee-script
loveencounterflow/coffy-script
lukhnos/doubleshot
lynaghk/coffee-script
martco/coffee-script
maxtaco/coffee-script
mbbx6spp/coffee-script
mblinn/coffee-script
mehmeta/coffee-script
melcher/coffee-script
mental/coffee-script
mhart/coffee-script
michaelficarra/coffee-script
misfo/coffee-script
mizchi/coffee-script
mlinderm/coffee-script
mrlauer/coffee-script-monads
muratmeran/coffee-script
myang/coffee-script
nanqiu/coffee-script
neobine/coffee-script
netconstructor/coffee-script
nickjs/coffee-script
nihar/coffee-script
onilabs/coffee-script
paiq/blackcoffee
parkerl/coffee-script
paulmars/coffee-script
peick/coffee-script
pjaspers/coffee-script
plambert/coffee-script
poutyface/coffee-script
pschyska/coffee-script
ptoomey3/coffee-script
quangv/coffee-script
revence27/coffee-script
rkJun/coffee-script
robarondaz/coffee-script
robotlolita/coffee-script
rolftimmermans/coffee-script
rpl/coffee-script
runeb/coffee-script
rwaldron/coffee-script
rymohr/coffee-script
ryszard/coffee-script
samcday/coffee-script
sarang25491/coffee-script
satyr/coffee-script
seedjs/coffee-script
sequoiar/coffee-script
sgraham/coffee-script
shariefsk/coffee-script
shesek/coffee-script
shimaore/cake
siefkenj/gjscoffee-script
smhanov/coffee-script
soutaro/coffee-script
spaghetticode/coffee-script
sparecycles/coffee-script
spencerelliott/coffee-script
sstephenson/coffee-script
stephank/coffee-script
strangemonad/coffee-script
swistak/coffee-script
syg/heap.coffee
taku0/coffee-script
tanob/coffee-script
tglines/coffee-script
thdtjsdn/coffee-script
theIntuitionist/coffee-script
thedeeno/coffee-script
thejh/coffee-script
timruffles/coffee-script
tkpage/coffee-script
tlrobinson/coffee-script
tmishra/coffee-script
tobee/coffee-script
tomelam/coffee-script
tosh/coffee-script
tswicegood/coffee-script
ttilley/coffee-script
twilson63/coffee-script
up2u0609/coffee-script
vanviegen/coffee-script
vjpr/coffee-script
vol4ok/coffee-script
walski/coffee-script
wearefractal/yerbascript
willmoffat/coffee-script
xixixao/coffee-script
yihuang/coffee-script
zaach/coffee-script
zmthy/coffee-script
zot/coffee-script
Nothing to show
Choose a base branch
Choose a Head Repository
jashkenas/coffeescript
CDR2003/coffee-script-lua
CreamCoderz/coffee-script
Crylock/coffee-script
GeoffreyBooth/coffeescript
Gregg/coffee-script
JulianBirch/coffee-script-1
JustinTulloss/coffee-script
MichaelBlume/coffee-script
NightMigera/coffeescript
PandaWood/coffee-script
ProximaMonkey/coffee-script
Remcoman/coffee-script
RicardoSaracino/coffee-script
SE7ENSKY/matescript
STRd6/coffee-script
ShawnFumo/coffee-script
StanAngeloff/coffee-script
Xepo/coffee-script
abi/coffee-script
agnoster/coffee-script
ahjohannessen/coffee-script
akiellor/coffee-script
alanning/coffee-script
allanberger/coffee-script
almost/coffee-script
alubbe/coffee-script
andrehjr/coffee-script
andrewschaaf/coffee-script
andreypopp/coffee-script
apanda/coffee-script
baoshitang/coffee-script
barberboy/coffee-script
benatkin/coffee-script
benbria/coffee-script
benekastah/coffee-script
bjouhier/coffee-script
blahutka/coffee-script
blossom/coffee-script
bolinfest/coffee-script
breckinloggins/coffee-script
carmelyne/contracts.coffee
chajath/coffee-script
charles-cai/coffee-script
charliesome/coffee-script
chetan51/coffee-script
chip/coffee-script
codelahoma/coffee-script
coffee-js/coffee-script
coffee-void/coffeescript
collin/coffee-script
danemorgridge/coffee-script
daveclarke/coffee-script
daveyoon/coffee-script
dbrans/coffee-script
deadprogram/coffee-script
devongovett/coffee-script
dget/coffee-script
disnet/contracts.coffee
dmohl/coffee-script
dohse/coffee-script
dqminh/coffee-script
drewlesueur/coffee-script
eventualbuddha/coffee-script
evilpie/coffee-script
excellentdrums/coffee-script
fitzgen/coffee-script
fizx/coffee-script
geraldalewis/coffee-script
germanocaldeira/coffee-script
gfodor/coffee-script
ghuntley/coffee-script
goodwink/coffee-script
gxela/coffee-script
hayeah/coffee-script
hbt/coffee-script
helixbass/copheescript
hleumas/coffee-script
holtwick/moccacino
hugs/coffee-script
ianthehenry/protoscript
ich/caffeine
janlelis/angular-coffee-script
jaredwy/coffee-script
jasonyandell/coffee-script
jawj/coffee-script
jbca/coffeescript
jiangmiao/toffee-script
jlstr/coffee-script
joelturnbull/coffee-script
johnsang/coffee-script
joliss/coffee-script
jondistad/coffee-script
joshprice/coffee-script
jstrachan/coffee-script
jugglinmike/irene-script
juilyoon/coffee-script
keichii/coffee-script
keithnorm/coffee-script
kewinwang/coffee-script
khaled/coffee-script
leeight/coffee-script
level1/coffee-script
lfendy/coffee-script
loganfsmyth/coffee-script
loopinfinito/coffeescript.com.br
lorensr/coffee-script
loveencounterflow/coffy-script
lukhnos/doubleshot
lynaghk/coffee-script
martco/coffee-script
maxtaco/coffee-script
mbbx6spp/coffee-script
mblinn/coffee-script
mehmeta/coffee-script
melcher/coffee-script
mental/coffee-script
mhart/coffee-script
michaelficarra/coffee-script
misfo/coffee-script
mizchi/coffee-script
mlinderm/coffee-script
mrlauer/coffee-script-monads
muratmeran/coffee-script
myang/coffee-script
nanqiu/coffee-script
neobine/coffee-script
netconstructor/coffee-script
nickjs/coffee-script
nihar/coffee-script
onilabs/coffee-script
paiq/blackcoffee
parkerl/coffee-script
paulmars/coffee-script
peick/coffee-script
pjaspers/coffee-script
plambert/coffee-script
poutyface/coffee-script
pschyska/coffee-script
ptoomey3/coffee-script
quangv/coffee-script
revence27/coffee-script
rkJun/coffee-script
robarondaz/coffee-script
robotlolita/coffee-script
rolftimmermans/coffee-script
rpl/coffee-script
runeb/coffee-script
rwaldron/coffee-script
rymohr/coffee-script
ryszard/coffee-script
samcday/coffee-script
sarang25491/coffee-script
satyr/coffee-script
seedjs/coffee-script
sequoiar/coffee-script
sgraham/coffee-script
shariefsk/coffee-script
shesek/coffee-script
shimaore/cake
siefkenj/gjscoffee-script
smhanov/coffee-script
soutaro/coffee-script
spaghetticode/coffee-script
sparecycles/coffee-script
spencerelliott/coffee-script
sstephenson/coffee-script
stephank/coffee-script
strangemonad/coffee-script
swistak/coffee-script
syg/heap.coffee
taku0/coffee-script
tanob/coffee-script
tglines/coffee-script
thdtjsdn/coffee-script
theIntuitionist/coffee-script
thedeeno/coffee-script
thejh/coffee-script
timruffles/coffee-script
tkpage/coffee-script
tlrobinson/coffee-script
tmishra/coffee-script
tobee/coffee-script
tomelam/coffee-script
tosh/coffee-script
tswicegood/coffee-script
ttilley/coffee-script
twilson63/coffee-script
up2u0609/coffee-script
vanviegen/coffee-script
vjpr/coffee-script
vol4ok/coffee-script
walski/coffee-script
wearefractal/yerbascript
willmoffat/coffee-script
xixixao/coffee-script
yihuang/coffee-script
zaach/coffee-script
zmthy/coffee-script
zot/coffee-script
Nothing to show
Choose a head branch
12
contributors
Commits on Oct 04, 2014
|
|
dtaniwaki |
Use stdio option instead of customFds
|
1301390
|
Commits on Feb 18, 2015
|
|
jashkenas |
#3862 changelog
|
61988fe
|
|||
|
|
jashkenas |
variable names
|
7395ac1
|
Commits on Feb 19, 2015
|
|
sgentle |
add -r/--require command line option
|
836175b
|
|||
|
|
jashkenas |
Merge pull request #3867 from sgentle/require-option
add -r/--require command line option |
f37f9d1
|
Commits on Feb 20, 2015
|
|
jcrben |
Replace references to jQuery's 'bind' with 'on'
|
88529bc
|
|||
|
|
jashkenas |
Merge pull request #3871 from jcrben/doc_tweak
Replace references to jQuery's 'bind' with 'on' |
8f5c77c
|
Commits on Feb 21, 2015
|
|
banyan |
Add link of changelog
|
50fff63
|
|||
|
|
banyan |
Delete README
|
ef6f907
|
Commits on Feb 22, 2015
|
|
Taritsyn |
Fix getting of character at index
|
71c59dd
|
Commits on Feb 23, 2015
|
|
jashkenas |
Merge pull request #3872 from banyan/add-link-of-changelog
Update README.md and remove README |
7a1c8fe
|
|||
|
|
jashkenas |
Merge pull request #3873 from Taritsyn/master
Fix getting of character at index |
c2758da
|
|||
|
|
gilesbowkett |
added descriptions to tests which only had Issue numbers
|
6645fbb
|
Commits on Feb 24, 2015
|
|
jashkenas |
Merge pull request #3877 from gilesbowkett/ocd-test-description-details
added descriptions to tests which only had Issue numbers |
06b7459
|
Commits on Feb 26, 2015
|
|
alubbe |
yield now behaves as expected around 'this' - fixes #3882
|
84c125a
|
|||
|
|
jashkenas |
Merge pull request #3883 from alubbe/master
yield now behaves as expected around 'this' |
c7a365b
|
|||
|
|
josh |
Escape literal `[` in regexp
Improves compatibility with strict ES5 regexp syntax |
7f77655
|
|||
|
|
jashkenas |
Merge pull request #3885 from josh/escape-literal-bracket-regexp
Escape literal [ in regexp |
9becb0e
|
|||
|
|
jashkenas |
Revert "Escape literal [ in regexp"
|
06aa329
|
|||
|
|
jashkenas |
Merge pull request #3886 from jashkenas/revert-3885-escape-literal-br…
…acket-regexp Revert "Escape literal [ in regexp" |
4a7497b
|
Commits on Mar 03, 2015
|
|
jashkenas |
Reverts #3758, Fixes #3863 -- kills the broken warning
|
c8147c0
|
Commits on Mar 06, 2015
|
|
jashkenas |
Merge pull request #3661 from dtaniwaki/fix-deprecated-option
Use stdio option instead of customFds |
a548b70
|
Commits on Mar 09, 2015
|
|
josh |
Escape literal ] in REGEX
] is not allowed in the PatternCharacter set |
8374491
|
|||
|
|
michaelficarra |
Merge pull request #3893 from josh/escape-literal-bracket-regexp
Escape literal ] in regexp |
37a3764
|
|||
|
|
matthieubulte |
Added checking on process.stdout to be compatible with browserify
|
3548b48
|
|||
|
|
imcotton |
optionally to read data-src out from <script>
|
cc1b056
|
|||
|
|
imcotton |
add compiled lib/browser.js
|
008bacf
|
|||
|
|
jashkenas |
Merge pull request #3706 from imcotton/script-data-src
Optionally to read data-src out from <script> |
0a3e363
|
|||
|
|
jashkenas |
Merge pull request #3892 from matthieubulte/master
Added checking on process.stdout to be compatible with browserify |
bd17cc9
|
Commits on Apr 15, 2015
Unified
Split
Showing
with
312 additions
and 218 deletions.
- +0 −50 README
- +2 −0 README.md
- +1 −1 bower.json
- +1 −1 documentation/coffee/fat_arrow.coffee
- +3 −2 documentation/docs/browser.html
- +1 −1 documentation/docs/coffee-script.html
- +14 −10 documentation/docs/command.html
- +1 −1 documentation/docs/helpers.html
- +2 −2 documentation/docs/lexer.html
- +1 −1 documentation/docs/nodes.html
- +8 −5 documentation/docs/repl.html
- +37 −9 documentation/index.html.js
- +1 −1 documentation/js/aliases.js
- +1 −1 documentation/js/array_comprehensions.js
- +1 −1 documentation/js/block_comment.js
- +1 −1 documentation/js/cake_tasks.js
- +1 −1 documentation/js/chaining.js
- +1 −1 documentation/js/classes.js
- +1 −1 documentation/js/comparisons.js
- +1 −1 documentation/js/conditionals.js
- +1 −1 documentation/js/constructor_destructuring.js
- +1 −1 documentation/js/default_args.js
- +1 −1 documentation/js/do.js
- +1 −1 documentation/js/embedded.js
- +1 −1 documentation/js/existence.js
- +1 −1 documentation/js/expansion.js
- +1 −1 documentation/js/expressions.js
- +1 −1 documentation/js/expressions_assignment.js
- +1 −1 documentation/js/expressions_comprehension.js
- +1 −1 documentation/js/expressions_try.js
- +2 −2 documentation/js/fat_arrow.js
- +1 −1 documentation/js/functions.js
- +1 −1 documentation/js/generators.js
- +1 −1 documentation/js/heredocs.js
- +1 −1 documentation/js/heregexes.js
- +1 −1 documentation/js/interpolation.js
- +1 −1 documentation/js/multiple_return_values.js
- +1 −1 documentation/js/object_comprehensions.js
- +1 −1 documentation/js/object_extraction.js
- +1 −1 documentation/js/objects_and_arrays.js
- +1 −1 documentation/js/objects_reserved.js
- +1 −1 documentation/js/overview.js
- +1 −1 documentation/js/parallel_assignment.js
- +1 −1 documentation/js/patterns_and_splats.js
- +1 −1 documentation/js/prototypes.js
- +1 −1 documentation/js/range_comprehensions.js
- +1 −1 documentation/js/scope.js
- +1 −1 documentation/js/slices.js
- +1 −1 documentation/js/soaks.js
- +1 −1 documentation/js/splats.js
- +1 −1 documentation/js/splices.js
- +1 −1 documentation/js/strings.js
- +1 −1 documentation/js/switch.js
- +1 −1 documentation/js/switch_with_no_expression.js
- +1 −1 documentation/js/try.js
- +1 −1 documentation/js/while.js
- +6 −6 extras/coffee-script.js
- +44 −12 index.html
- +5 −4 lib/coffee-script/browser.js
- +1 −1 lib/coffee-script/cake.js
- +2 −2 lib/coffee-script/coffee-script.js
- +22 −13 lib/coffee-script/command.js
- +1 −1 lib/coffee-script/grammar.js
- +4 −4 lib/coffee-script/helpers.js
- +1 −1 lib/coffee-script/index.js
- +3 −3 lib/coffee-script/lexer.js
- +3 −3 lib/coffee-script/nodes.js
- +1 −1 lib/coffee-script/optparse.js
- +1 −1 lib/coffee-script/register.js
- +15 −5 lib/coffee-script/repl.js
- +1 −1 lib/coffee-script/rewriter.js
- +1 −1 lib/coffee-script/scope.js
- +1 −1 lib/coffee-script/sourcemap.js
- +1 −1 package.json
- +3 −2 src/browser.coffee
- +1 −1 src/coffee-script.coffee
- +12 −8 src/command.coffee
- +1 −1 src/helpers.coffee
- +2 −2 src/lexer.coffee
- +1 −1 src/nodes.coffee
- +8 −5 src/repl.coffee
- +2 −2 test/assignment.coffee
- +2 −2 test/compilation.coffee
- +1 −1 test/control_flow.coffee
- +47 −0 test/generators.coffee
- +3 −4 test/soaks.coffee
View
50
README
| @@ -1,50 +0,0 @@ | ||
| - { | ||
| - } } { | ||
| - { { } } | ||
| - } }{ { | ||
| - { }{ } } _____ __ __ | ||
| - { }{ }{ { } / ____| / _|/ _| | ||
| - .- { { } { }} -. | | ___ | |_| |_ ___ ___ | ||
| - ( { } { } { } } ) | | / _ \| _| _/ _ \/ _ \ | ||
| - |`-..________ ..-'| | |___| (_) | | | || __/ __/ | ||
| - | | \_____\___/|_| |_| \___|\___| | ||
| - | ;--. | ||
| - | (__ \ _____ _ _ | ||
| - | | ) ) / ____| (_) | | | ||
| - | |/ / | (___ ___ _ __ _ _ __ | |_ | ||
| - | ( / \___ \ / __| '__| | '_ \| __| | ||
| - | |/ ____) | (__| | | | |_) | |_ | ||
| - | | |_____/ \___|_| |_| .__/ \__| | ||
| - `-.._________..-' | | | ||
| - |_| | ||
| - | ||
| - | ||
| - CoffeeScript is a little language that compiles into JavaScript. | ||
| - | ||
| - If you have the Node Package Manager installed: | ||
| - npm install -g coffee-script | ||
| - (Leave off the -g if you don't wish to install globally.) | ||
| - | ||
| - Or, if you don't wish to use npm: | ||
| - sudo bin/cake install | ||
| - | ||
| - Execute a script: | ||
| - coffee /path/to/script.coffee | ||
| - | ||
| - Compile a script: | ||
| - coffee -c /path/to/script.coffee | ||
| - | ||
| - For documentation, usage, and examples, see: | ||
| - http://coffeescript.org/ | ||
| - | ||
| - To suggest a feature, report a bug, or general discussion: | ||
| - http://github.com/jashkenas/coffeescript/issues/ | ||
| - | ||
| - If you'd like to chat, drop by #coffeescript on Freenode IRC, | ||
| - or on webchat.freenode.net. | ||
| - | ||
| - The source repository: | ||
| - git://github.com/jashkenas/coffeescript.git | ||
| - | ||
| - Top 100 contributors are listed here: | ||
| - http://github.com/jashkenas/coffeescript/contributors |
View
2
README.md
| @@ -57,4 +57,6 @@ If you'd like to chat, drop by #coffeescript on Freenode IRC. | ||
| The source repository: https://github.com/jashkenas/coffeescript.git | ||
| +Changelog: http://coffeescript.org/#changelog | ||
| + | ||
| Our lovely and talented contributors are listed here: http://github.com/jashkenas/coffeescript/contributors | ||
View
2
bower.json
| @@ -1,6 +1,6 @@ | ||
| { | ||
| "name": "coffee-script", | ||
| - "version": "1.9.1", | ||
| + "version": "1.9.2", | ||
| "main": [ | ||
| "lib/coffee-script/coffee-script.js" | ||
| ], | ||
View
2
documentation/coffee/fat_arrow.coffee
| @@ -2,5 +2,5 @@ Account = (customer, cart) -> | ||
| @customer = customer | ||
| @cart = cart | ||
| - $('.shopping_cart').bind 'click', (event) => | ||
| + $('.shopping_cart').on 'click', (event) => | ||
| @customer.purchase @cart | ||
View
5
documentation/docs/browser.html
| @@ -261,8 +261,9 @@ | ||
| <span class="hljs-keyword">for</span> script, i <span class="hljs-keyword">in</span> coffees | ||
| <span class="hljs-keyword">do</span> <span class="hljs-function"><span class="hljs-params">(script, i)</span> -></span> | ||
| options = <span class="hljs-attribute">literate</span>: script.type <span class="hljs-keyword">is</span> coffeetypes[<span class="hljs-number">1</span>] | ||
| - <span class="hljs-keyword">if</span> script.src | ||
| - CoffeeScript.load script.src, | ||
| + source = script.src <span class="hljs-keyword">or</span> script.getAttribute(<span class="hljs-string">'data-src'</span>) | ||
| + <span class="hljs-keyword">if</span> source | ||
| + CoffeeScript.load source, | ||
| <span class="hljs-function"><span class="hljs-params">(param)</span> -></span> | ||
| coffees[i] = param | ||
| execute() | ||
View
2
documentation/docs/coffee-script.html
| @@ -144,7 +144,7 @@ | ||
| </div> | ||
| - <div class="content"><div class='highlight'><pre><span class="hljs-built_in">exports</span>.VERSION = <span class="hljs-string">'1.9.1'</span> | ||
| + <div class="content"><div class='highlight'><pre><span class="hljs-built_in">exports</span>.VERSION = <span class="hljs-string">'1.9.2'</span> | ||
| <span class="hljs-built_in">exports</span>.FILE_EXTENSIONS = [<span class="hljs-string">'.coffee'</span>, <span class="hljs-string">'.litcoffee'</span>, <span class="hljs-string">'.coffee.md'</span>]</pre></div></div> | ||
View
24
documentation/docs/command.html
| @@ -211,6 +211,7 @@ | ||
| [ <span class="hljs-string">'--no-header'</span>, <span class="hljs-string">'suppress the "Generated by" header'</span>] | ||
| [<span class="hljs-string">'-o'</span>, <span class="hljs-string">'--output [DIR]'</span>, <span class="hljs-string">'set the output directory for compiled JavaScript'</span>] | ||
| [<span class="hljs-string">'-p'</span>, <span class="hljs-string">'--print'</span>, <span class="hljs-string">'print out the compiled JavaScript'</span>] | ||
| + [<span class="hljs-string">'-r'</span>, <span class="hljs-string">'--require [MODULE*]'</span>, <span class="hljs-string">'require the given module before eval or REPL'</span>] | ||
| [<span class="hljs-string">'-s'</span>, <span class="hljs-string">'--stdio'</span>, <span class="hljs-string">'listen for and compile scripts over stdio'</span>] | ||
| [<span class="hljs-string">'-l'</span>, <span class="hljs-string">'--literate'</span>, <span class="hljs-string">'treat stdio as literate style coffee-script'</span>] | ||
| [<span class="hljs-string">'-t'</span>, <span class="hljs-string">'--tokens'</span>, <span class="hljs-string">'print out the tokens that the lexer/rewriter produce'</span>] | ||
| @@ -236,8 +237,7 @@ | ||
| sourceCode = [] | ||
| notSources = {} | ||
| watchedDirs = {} | ||
| -optionParser = <span class="hljs-literal">null</span> | ||
| -jsToSources = {}</pre></div></div> | ||
| +optionParser = <span class="hljs-literal">null</span></pre></div></div> | ||
| </li> | ||
| @@ -273,6 +273,8 @@ | ||
| </div> | ||
| <div class="content"><div class='highlight'><pre> replCliOpts = <span class="hljs-attribute">useGlobal</span>: <span class="hljs-literal">yes</span> | ||
| + opts.prelude = makePrelude opts.<span class="hljs-built_in">require</span> <span class="hljs-keyword">if</span> opts.<span class="hljs-built_in">require</span> | ||
| + replCliOpts.prelude = opts.prelude | ||
| <span class="hljs-keyword">return</span> forkNode() <span class="hljs-keyword">if</span> opts.nodejs | ||
| <span class="hljs-keyword">return</span> usage() <span class="hljs-keyword">if</span> opts.help | ||
| <span class="hljs-keyword">return</span> version() <span class="hljs-keyword">if</span> opts.version | ||
| @@ -303,7 +305,14 @@ | ||
| '''</span> | ||
| <span class="hljs-keyword">for</span> source <span class="hljs-keyword">in</span> opts.arguments | ||
| source = path.resolve source | ||
| - compilePath source, <span class="hljs-literal">yes</span>, source</pre></div></div> | ||
| + compilePath source, <span class="hljs-literal">yes</span>, source | ||
| + | ||
| +<span class="hljs-function"><span class="hljs-title">makePrelude</span> = <span class="hljs-params">(requires)</span> -></span> | ||
| + requires.map <span class="hljs-function"><span class="hljs-params">(<span class="hljs-built_in">module</span>)</span> -></span> | ||
| + [_, name, <span class="hljs-built_in">module</span>] = match <span class="hljs-keyword">if</span> match = <span class="hljs-built_in">module</span>.match(<span class="hljs-regexp">/^(.*)=(.*)$/</span>) | ||
| + name ||= helpers.baseFileName <span class="hljs-built_in">module</span>, <span class="hljs-literal">yes</span>, useWinPathSep | ||
| + <span class="hljs-string">"<span class="hljs-subst">#{name}</span> = require('<span class="hljs-subst">#{<span class="hljs-built_in">module</span>}</span>')"</span> | ||
| + .join <span class="hljs-string">';'</span></pre></div></div> | ||
| </li> | ||
| @@ -395,6 +404,7 @@ | ||
| printLine CoffeeScript.nodes(t.input, t.options).toString().trim() | ||
| <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.run | ||
| CoffeeScript.register() | ||
| + CoffeeScript.eval opts.prelude, t.options <span class="hljs-keyword">if</span> opts.prelude | ||
| CoffeeScript.run t.input, t.options | ||
| <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.join <span class="hljs-keyword">and</span> t.file <span class="hljs-keyword">isnt</span> o.join | ||
| t.input = helpers.invertLiterate t.input <span class="hljs-keyword">if</span> helpers.isLiterate file | ||
| @@ -676,12 +686,6 @@ | ||
| <div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">writeJs</span> = <span class="hljs-params">(base, sourcePath, js, jsPath, generatedSourceMap = <span class="hljs-literal">null</span>)</span> -></span> | ||
| sourceMapPath = outputPath sourcePath, base, <span class="hljs-string">".js.map"</span> | ||
| jsDir = path.dirname jsPath | ||
| - <span class="hljs-keyword">if</span> jsPath <span class="hljs-keyword">of</span> jsToSources | ||
| - printLine <span class="hljs-string">"Error: The two following source files have the same output file:"</span> | ||
| - printLine <span class="hljs-string">" "</span> + jsToSources[jsPath] | ||
| - printLine <span class="hljs-string">" "</span> + sourcePath | ||
| - process.exit <span class="hljs-number">1</span> | ||
| - jsToSources[jsPath] = sourcePath | ||
| <span class="hljs-function"><span class="hljs-title">compile</span> = -></span> | ||
| <span class="hljs-keyword">if</span> opts.compile | ||
| js = <span class="hljs-string">' '</span> <span class="hljs-keyword">if</span> js.length <= <span class="hljs-number">0</span> | ||
| @@ -832,7 +836,7 @@ | ||
| p = spawn process.execPath, nodeArgs.concat(args), | ||
| <span class="hljs-attribute">cwd</span>: process.cwd() | ||
| <span class="hljs-attribute">env</span>: process.env | ||
| - <span class="hljs-attribute">customFds</span>: [<span class="hljs-number">0</span>, <span class="hljs-number">1</span>, <span class="hljs-number">2</span>] | ||
| + <span class="hljs-attribute">stdio</span>: [<span class="hljs-number">0</span>, <span class="hljs-number">1</span>, <span class="hljs-number">2</span>] | ||
| p.<span class="hljs-literal">on</span> <span class="hljs-string">'exit'</span>, <span class="hljs-function"><span class="hljs-params">(code)</span> -></span> process.exit code</pre></div></div> | ||
| </li> | ||
View
2
documentation/docs/helpers.html
| @@ -583,7 +583,7 @@ | ||
| </div> | ||
| <div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> process? | ||
| - colorsEnabled = process.stdout.isTTY <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> process.env.NODE_DISABLE_COLORS | ||
| + colorsEnabled = process.stdout?.isTTY <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> process.env?.NODE_DISABLE_COLORS | ||
| <span class="hljs-keyword">if</span> <span class="hljs-property">@colorful</span> ? colorsEnabled | ||
| <span class="hljs-function"><span class="hljs-title">colorize</span> = <span class="hljs-params">(str)</span> -></span> <span class="hljs-string">"\x1B[1;31m<span class="hljs-subst">#{str}</span>\x1B[0m"</span> | ||
View
4
documentation/docs/lexer.html
| @@ -484,7 +484,7 @@ <h2 id="tokenizers">Tokenizers</h2> | ||
| {tokens, <span class="hljs-attribute">index</span>: end} = <span class="hljs-property">@matchWithInterpolations</span> regex, quote | ||
| $ = tokens.length - <span class="hljs-number">1</span> | ||
| - delimiter = quote[<span class="hljs-number">0</span>] | ||
| + delimiter = quote.charAt(<span class="hljs-number">0</span>) | ||
| <span class="hljs-keyword">if</span> heredoc</pre></div></div> | ||
| </li> | ||
| @@ -1766,7 +1766,7 @@ <h2 id="constants">Constants</h2> | ||
| | \\[^\n] <span class="hljs-comment"># anything but newlines escaped</span> | ||
| | \[ <span class="hljs-comment"># character class</span> | ||
| (?: \\[^\n] | [^ \] \n \\ ] )* | ||
| - ] | ||
| + \] | ||
| )*) (/)? | ||
| ///</span> | ||
View
2
documentation/docs/nodes.html
| @@ -328,7 +328,7 @@ <h3 id="base">Base</h3> | ||
| meth = <span class="hljs-string">'call'</span> | ||
| func = <span class="hljs-keyword">new</span> Value func, [<span class="hljs-keyword">new</span> Access <span class="hljs-keyword">new</span> Literal meth] | ||
| parts = (<span class="hljs-keyword">new</span> Call func, args).compileNode o | ||
| - <span class="hljs-keyword">if</span> func.isGenerator | ||
| + <span class="hljs-keyword">if</span> func.isGenerator <span class="hljs-keyword">or</span> func.base?.isGenerator | ||
| parts.unshift <span class="hljs-property">@makeCode</span> <span class="hljs-string">"(yield* "</span> | ||
| parts.push <span class="hljs-property">@makeCode</span> <span class="hljs-string">")"</span> | ||
| parts</pre></div></div> | ||
View
13
documentation/docs/repl.html
| @@ -243,11 +243,7 @@ | ||
| <span class="hljs-keyword">new</span> Assign (<span class="hljs-keyword">new</span> Value <span class="hljs-keyword">new</span> Literal <span class="hljs-string">'_'</span>), ast, <span class="hljs-string">'='</span> | ||
| ] | ||
| js = ast.compile {<span class="hljs-attribute">bare</span>: <span class="hljs-literal">yes</span>, <span class="hljs-attribute">locals</span>: Object.keys(context), referencedVars} | ||
| - result = <span class="hljs-keyword">if</span> context <span class="hljs-keyword">is</span> <span class="hljs-built_in">global</span> | ||
| - vm.runInThisContext js, filename | ||
| - <span class="hljs-keyword">else</span> | ||
| - vm.runInContext js, context, filename | ||
| - cb <span class="hljs-literal">null</span>, result | ||
| + cb <span class="hljs-literal">null</span>, runInContext js, context, filename | ||
| <span class="hljs-keyword">catch</span> err</pre></div></div> | ||
| </li> | ||
| @@ -266,6 +262,12 @@ | ||
| <div class="content"><div class='highlight'><pre> updateSyntaxError err, input | ||
| cb err | ||
| +<span class="hljs-function"><span class="hljs-title">runInContext</span> = <span class="hljs-params">(js, context, filename)</span> -></span> | ||
| + <span class="hljs-keyword">if</span> context <span class="hljs-keyword">is</span> <span class="hljs-built_in">global</span> | ||
| + vm.runInThisContext js, filename | ||
| + <span class="hljs-keyword">else</span> | ||
| + vm.runInContext js, context, filename | ||
| + | ||
| <span class="hljs-function"><span class="hljs-title">addMultilineHandler</span> = <span class="hljs-params">(repl)</span> -></span> | ||
| {rli, inputStream, outputStream} = repl</pre></div></div> | ||
| @@ -576,6 +578,7 @@ | ||
| process.argv = [<span class="hljs-string">'coffee'</span>].concat process.argv[<span class="hljs-number">2.</span>.] | ||
| opts = merge replDefaults, opts | ||
| repl = nodeREPL.start opts | ||
| + runInContext opts.prelude, repl.context, <span class="hljs-string">'prelude'</span> <span class="hljs-keyword">if</span> opts.prelude | ||
| repl.<span class="hljs-literal">on</span> <span class="hljs-string">'exit'</span>,<span class="hljs-function"> -></span> repl.outputStream.write <span class="hljs-string">'\n'</span> | ||
| addMultilineHandler repl | ||
| addHistory repl, opts.historyFile, opts.historyMaxInputSize <span class="hljs-keyword">if</span> opts.historyFile</pre></div></div> | ||
View
46
documentation/index.html.js
| @@ -110,7 +110,7 @@ | ||
| <p> | ||
| <b>Latest Version:</b> | ||
| - <a href="http://github.com/jashkenas/coffeescript/tarball/1.9.1">1.9.1</a> | ||
| + <a href="http://github.com/jashkenas/coffeescript/tarball/1.9.2">1.9.2</a> | ||
| </p> | ||
| <pre>npm install -g coffee-script</pre> | ||
| @@ -806,7 +806,7 @@ Expressions | ||
| it to the current value of <tt>this</tt>, right on the spot. This is helpful | ||
| when using callback-based libraries like Prototype or jQuery, for creating | ||
| iterator functions to pass to <tt>each</tt>, or event-handler functions | ||
| - to use with <tt>bind</tt>. Functions created with the fat arrow are able to access | ||
| + to use with <tt>on</tt>. Functions created with the fat arrow are able to access | ||
| properties of the <tt>this</tt> where they're defined. | ||
| </p> | ||
| <%= codeFor('fat_arrow') %> | ||
| @@ -821,9 +821,9 @@ Expressions | ||
| constructed. | ||
| </p> | ||
| <p> | ||
| - CoffeeScript functions also support | ||
| + CoffeeScript functions also support | ||
| <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function*">ES6 generator functions</a> | ||
| - through the <tt>yield</tt> keyword. There's no <tt>function*(){}</tt> | ||
| + through the <tt>yield</tt> keyword. There's no <tt>function*(){}</tt> | ||
| nonsense — a generator in CoffeeScript is simply a function that yields. | ||
| </p> | ||
| <%= codeFor('generators', 'ps.next().value') %> | ||
| @@ -1204,20 +1204,48 @@ Expressions | ||
| </h2> | ||
| <p> | ||
| + <%= releaseHeader('2015-04-15', '1.9.2', '1.9.1') %> | ||
| + <ul> | ||
| + <li> | ||
| + Fixed a <b>watch</b> mode error introduced in 1.9.1 when compiling | ||
| + multiple files with the same filename. | ||
| + </li> | ||
| + <li> | ||
| + Bugfix for <tt>yield</tt> around expressions containing | ||
| + <tt>this</tt>. | ||
| + </li> | ||
| + <li> | ||
| + Added a Ruby-style <tt>-r</tt> option to the REPL, which allows | ||
| + requiring a module before execution with <tt>--eval</tt> or | ||
| + <tt>--interactive</tt>. | ||
| + </li> | ||
| + <li> | ||
| + In <tt><script type="text/coffeescript"></tt> tags, to avoid | ||
| + possible duplicate browser requests for .coffee files, | ||
| + you can now use the <tt>data-src</tt> attribute instead of <tt>src</tt>. | ||
| + </li> | ||
| + <li> | ||
| + Minor bug fixes for IE8, strict ES5 regular expressions and Browserify. | ||
| + </li> | ||
| + </ul> | ||
| + </p> | ||
| + | ||
| + <p> | ||
| <%= releaseHeader('2015-02-18', '1.9.1', '1.9.0') %> | ||
| <ul> | ||
| <li> | ||
| - Interpolation now works in object literal keys (again). You can use this to | ||
| + Interpolation now works in object literal keys (again). You can use this to | ||
| dynamically name properties. | ||
| </li> | ||
| <li> | ||
| - Internal compiler names no longer start with underscores. This makes | ||
| + Internal compiler variable names no longer start with underscores. This makes | ||
| the generated JavaScript a bit prettier, and also fixes an issue with | ||
| the completely broken and ungodly way that AngularJS "parses" function | ||
| arguments. | ||
| </li> | ||
| <li> | ||
| - Fixed a few <tt>yield</tt>-related bugs. | ||
| + Fixed a few <tt>yield</tt>-related edge cases with <tt>yield return</tt> | ||
| + and <tt>yield throw</tt>. | ||
| </li> | ||
| <li> | ||
| Minor bug fixes and various improvements to compiler error messages. | ||
| @@ -1230,10 +1258,10 @@ Expressions | ||
| <ul> | ||
| <li> | ||
| CoffeeScript now supports ES6 generators. A generator is simply a function | ||
| - that <tt>yield</tt>s. | ||
| + that <tt>yield</tt>s. | ||
| </li> | ||
| <li> | ||
| - More robust parsing and improved error messages for strings and regexes — | ||
| + More robust parsing and improved error messages for strings and regexes — | ||
| especially with respect to interpolation. | ||
| </li> | ||
| <li> | ||
View
2
documentation/js/aliases.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| var volume, winner; | ||
| if (ignition === true) { | ||
View
2
documentation/js/array_comprehensions.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| var courses, dish, food, foods, i, j, k, l, len, len1, len2, ref; | ||
| ref = ['toast', 'cheese', 'wine']; | ||
View
2
documentation/js/block_comment.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| /* | ||
| SkinnyMochaHalfCaffScript Compiler v1.0 | ||
View
2
documentation/js/cake_tasks.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| var fs; | ||
| fs = require('fs'); | ||
View
2
documentation/js/chaining.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| $('body').click(function(e) { | ||
| return $('.box').fadeIn('fast').addClass('.active'); | ||
| }).css('background', 'white'); |
View
2
documentation/js/classes.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| var Animal, Horse, Snake, sam, tom, | ||
| extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, | ||
| hasProp = {}.hasOwnProperty; | ||
View
2
documentation/js/comparisons.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| var cholesterol, healthy; | ||
| cholesterol = 127; | ||
View
2
documentation/js/conditionals.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| var date, mood; | ||
| if (singing) { | ||
View
2
documentation/js/constructor_destructuring.js
| @@ -1,4 +1,4 @@ | ||
| -// Generated by CoffeeScript 1.9.1 | ||
| +// Generated by CoffeeScript 1.9.2 | ||
| var Person, tim; | ||
| Person = (function() { | ||
Oops, something went wrong.