Jeremy Ashkenas
eef83a9fcb
CoffeeScript 1.6.1
2013-03-05 11:07:16 +13:00
Jeremy Ashkenas
b62a90d54c
Fixes #2765 -- incorrect line number in mappings
2013-03-05 10:49:47 +13:00
Jeremy Ashkenas
b2ef77d92e
refactoring to a baseFileName that can work in the browser, for later
2013-03-05 10:40:39 +13:00
Jeremy Ashkenas
b2b801a78b
Fixes #2766 -- incompatible line number API
2013-03-05 10:19:21 +13:00
Jeremy Ashkenas
b4c12f6746
Fixing lingering brain fart. Inexcusable.
2013-03-05 09:23:50 +13:00
Matthew Tretter
3c42a8e01c
Update compiled version
2013-03-04 15:07:20 -05:00
Jeremy Ashkenas
9f614fedec
CoffeeScript 1.6.0
2013-03-05 08:19:08 +13:00
Jeremy Ashkenas
e417a0ca6f
Reverts 56fe211b79
2013-03-05 07:38:41 +13:00
Jeremy Ashkenas
75769503ff
Renaming --maps option to --map for consistency.
2013-03-05 07:29:46 +13:00
Jason Walton
979e110a84
Minor API changes.
2013-03-04 09:45:25 -05:00
Jason Walton
96785872cd
Merge remote-tracking branch 'upstream/master' into sourcemaps
...
Conflicts:
lib/coffee-script/coffee-script.js
lib/coffee-script/command.js
lib/coffee-script/nodes.js
src/coffee-script.coffee
src/command.coffee
src/nodes.coffee
2013-03-04 09:25:55 -05:00
Troels Nielsen
37a6ea63b1
#2757 , Allow non-significant commas at end of nested implicit objects
2013-03-04 12:55:15 +01:00
Jeremy Ashkenas
56fe211b79
Fixes #2455 -- condition should know what variables the body has declared.
2013-03-04 23:33:50 +13:00
Jeremy Ashkenas
cf11a570e9
Fixes #2489 , fixes #1819 , fixes #1821 -- remove the __bind helper.
2013-03-04 23:11:38 +13:00
Jeremy Ashkenas
9fe0e711d6
Fixes #2502 -- improper compilation with parenthesized inner value of instance properties in a class body.
2013-03-04 22:26:55 +13:00
Jeremy Ashkenas
b3452c1276
Fixes #2508 -- existential access of the prototype.
2013-03-04 22:07:47 +13:00
Jeremy Ashkenas
47f0ea69b8
Fixes #2749 . Restricting to instance methods in class bodies, where it actually has a chance in hell of calling the correct thing.
2013-03-04 21:26:01 +13:00
Jeremy Ashkenas
667b96b495
Fixes #2750 -- clarify error message
2013-03-04 21:17:26 +13:00
Jeremy Ashkenas
3b25aea168
When printing out --tokens, hide the location data.
2013-03-04 20:54:45 +13:00
Marc Häfner
3c38a34ab2
Fix line numbers when first line is indented.
...
* Offset @chunkLine for inserted line break.
* Avoid line break insertion for blank lines.
2013-03-01 21:30:07 +01:00
Jason Walton
ad0306b00c
Change compileWithSourceMap() so it returns an object instead of an Array, and return the SourceMap object.
2013-03-01 11:34:39 -05:00
Jason Walton
ea86e3e7b1
Optionally allow replacement of existing mappings in SourceMap#addMapping().
2013-03-01 10:18:37 -05:00
Jason Walton
844549954a
Minor API clean up, and make it so sourcemaps are pretty-printed to the .map file.
2013-03-01 10:12:10 -05:00
Jason Walton
51fe417d58
Fix generated file name in v3 source map
2013-03-01 08:56:17 -05:00
Jason Walton
0e718f0968
Merge branch 'sourcemaps' of https://github.com/surjikal/coffee-script into sourcemaps
2013-03-01 08:47:42 -05:00
Jason Walton
0d6d479d77
Merge branch 'master' into sourcemaps
...
Conflicts:
lib/coffee-script/coffee-script.js
lib/coffee-script/nodes.js
src/nodes.coffee
2013-03-01 08:47:16 -05:00
Nicolas Porter
88e02322e5
Fixed key name in source map, added coffee file to map sources
...
These are the modifications I had to do in order to get source maps working
in 27.0.1425.2 (Official Build 185250) canary. I haven't tested other
browsers.
I first looked at the V3 spec and a few examples, and I saw that the
`source` key of the source map should be called `sources`.
After doing the `source` to `sources` change, the coffee source and for
some odd reason the javascript file would not show up in the browser
dev tools (it was being fetched but not evaluated).
To fix this, I had to add the coffee source to the `sources` list in the
source map file.
2013-03-01 05:58:26 -05:00
Jeremy Ashkenas
5dea70b82e
Fixes #2721 -- show error message for naked super
2013-03-01 13:25:49 +13:00
Jeremy Ashkenas
6b79af2b7c
Fixes #2721 , super outside of classes with extends for instance methods.
2013-03-01 13:17:07 +13:00
Jeremy Ashkenas
68718b6938
Moving path dependency back into 'command'
2013-03-01 12:50:42 +13:00
Jeremy Ashkenas
d70d71f574
Merging in .coffee.md support alongside .litcoffee ... I think we'll keep .litcoffee as the canonical, however.
2013-03-01 12:46:40 +13:00
Jeremy Ashkenas
f33517368e
Removing duplicate 'CATCH'
2013-03-01 12:38:41 +13:00
Troels Nielsen
71e04d9839
Disallow implicit calls in cases like:
...
f
a
and only allow cases like:
f
a: 1
2013-02-28 23:20:42 +01:00
Jeremy Ashkenas
2970d59395
Merge pull request #2743 from epidemian/revert-2599
...
Revert #2599
2013-02-28 13:53:34 -08:00
Jason Walton
7073d18f23
Add source map support
2013-02-28 15:51:29 -05:00
Jeremy Ashkenas
23d8cd6c2a
Merge branch 'master' of https://github.com/jashkenas/coffee-script
2013-03-01 07:46:04 +13:00
Jeremy Ashkenas
e70dd156b0
Fixing heredocs in literate coffeescript
2013-03-01 07:42:12 +13:00
Demian Ferreiro
bf70b4660e
Revert #2599
2013-02-28 10:37:30 -03:00
Jeremy Ashkenas
c0e07013e8
Merge pull request #2741 from troels/implicit-call-try-catch-finally
...
Fix implicit calls with try/catch/finally as arguments
2013-02-28 03:00:49 -08:00
Jeremy Ashkenas
c6f30935a8
(Aside: For historical reasons we do make the filename extension optional, which is a deeply regrettable accident of history that I would not repeat, given the chance.)
2013-02-28 23:54:19 +13:00
Troels Nielsen
cb187fd900
Fix implicit calls with try/catch/finally as arguments
2013-02-28 11:53:04 +01:00
Jeremy Ashkenas
3f23be2854
Merge pull request #2718 from sbp/sbp-literate
...
Add support for text/literate-coffeescript in the browser
2013-02-28 02:47:43 -08:00
Sean B. Palmer
881ae5528d
Add support for text/literate-coffeescript in the browser
2013-02-28 10:15:20 +00:00
Michael Smith
1a8354482a
Modify extension handling to allow for .coffee.md
...
Move filename processing to a `parseFileName` function in
helpers.coffee.
Map `.coffee.md` as a Literate CoffeeScript extension.
Also, make .litcoffee and .coffee.md files executable without their file
extension - eg. `coffee test` would work for a file called
`test.litcoffee`.
2013-02-27 22:49:24 -08:00
Troels Nielsen
1666716c31
Improve the handling of implicit object and implicit call combinations
...
by handling them together.
2013-02-27 08:15:38 +01:00
Jason Walton
541ab8334d
Compile to an array of CodeFragments instead of to a giant string.
2013-02-26 13:34:27 -05:00
Michael Smith
ff1ddd0284
Fix repl handling of blank line
...
Since the move to the nodeREPL package, input lines to be evaluated are
now wrapped in parentheses; that is:
'foo'
would become:
('foo'
)
The old way of detecting empty lines was to see if the input string was
either totally empty, or whitespace-only. The addition of these
parentheses breaks that.
In order to fix this, we simply tweak the regex a little to ignore these
added parentheses if they're present. As an added bonus, the regex
should match empty inputs even if they aren't.
This also makes the "empty command evaluates to undefined" test pass,
for the right reasons (i.e. not because of the broken error behavior
from before).
2013-02-25 22:09:50 -08:00
Michael Smith
deaa31dca5
Prevent repl from crashing on error [ Fixes #2716 ]
...
Move execution of the compiled code inside the try/catch block:
try
js = CoffeeScript.compile "_=(#{input}\n)", {filename, bare: yes}
catch err
cb err
> cb null, vm.runInContext(js, context, filename)
try
js = CoffeeScript.compile "_=(#{input}\n)", {filename, bare: yes}
> cb null, vm.runInContext(js, context, filename)
catch err
cb err
2013-02-25 22:08:01 -08:00
Demian Ferreiro
f609036bee
Remove unnecessary returns and use default parameters
2013-02-25 10:44:56 -03:00
Jeremy Ashkenas
af53c230a1
CoffeeScript 1.5.0
2013-02-25 21:12:22 +13:00