Permalink
Browse files

CoffeeScript 1.3.1 (quick bugfix for compound assignment to a global …

…variable
  • Loading branch information...
1 parent f0e17fc commit 60c9b94656c4329929fe8c5294899de42a3e3eff @jashkenas committed Apr 10, 2012
Showing with 69 additions and 68 deletions.
  1. +1 −1 documentation/coffee/block_comment.coffee
  2. +1 −1 documentation/docs/coffee-script.html
  3. +2 −1 documentation/docs/nodes.html
  4. +2 −2 documentation/index.html.erb
  5. +1 −1 documentation/js/aliases.js
  6. +1 −1 documentation/js/array_comprehensions.js
  7. +2 −2 documentation/js/block_comment.js
  8. +1 −1 documentation/js/cake_tasks.js
  9. +1 −1 documentation/js/classes.js
  10. +1 −1 documentation/js/comparisons.js
  11. +1 −1 documentation/js/conditionals.js
  12. +1 −1 documentation/js/default_args.js
  13. +1 −1 documentation/js/do.js
  14. +1 −1 documentation/js/embedded.js
  15. +1 −1 documentation/js/existence.js
  16. +1 −1 documentation/js/expressions.js
  17. +1 −1 documentation/js/expressions_assignment.js
  18. +1 −1 documentation/js/expressions_comprehension.js
  19. +1 −1 documentation/js/expressions_try.js
  20. +1 −1 documentation/js/fat_arrow.js
  21. +1 −1 documentation/js/functions.js
  22. +1 −1 documentation/js/heredocs.js
  23. +1 −1 documentation/js/heregexes.js
  24. +1 −1 documentation/js/interpolation.js
  25. +1 −1 documentation/js/multiple_return_values.js
  26. +1 −1 documentation/js/object_comprehensions.js
  27. +1 −1 documentation/js/object_extraction.js
  28. +1 −1 documentation/js/objects_and_arrays.js
  29. +1 −1 documentation/js/objects_reserved.js
  30. +1 −1 documentation/js/overview.js
  31. +1 −1 documentation/js/parallel_assignment.js
  32. +1 −1 documentation/js/patterns_and_splats.js
  33. +1 −1 documentation/js/prototypes.js
  34. +1 −1 documentation/js/range_comprehensions.js
  35. +1 −1 documentation/js/scope.js
  36. +1 −1 documentation/js/slices.js
  37. +1 −1 documentation/js/soaks.js
  38. +1 −1 documentation/js/splats.js
  39. +1 −1 documentation/js/splices.js
  40. +1 −1 documentation/js/strings.js
  41. +1 −1 documentation/js/switch.js
  42. +1 −1 documentation/js/try.js
  43. +1 −1 documentation/js/while.js
  44. +2 −2 extras/coffee-script.js
  45. +5 −5 index.html
  46. +1 −1 lib/coffee-script/browser.js
  47. +1 −1 lib/coffee-script/cake.js
  48. +2 −2 lib/coffee-script/coffee-script.js
  49. +1 −1 lib/coffee-script/command.js
  50. +1 −1 lib/coffee-script/grammar.js
  51. +1 −1 lib/coffee-script/helpers.js
  52. +1 −1 lib/coffee-script/index.js
  53. +1 −1 lib/coffee-script/lexer.js
  54. +1 −1 lib/coffee-script/nodes.js
  55. +1 −1 lib/coffee-script/optparse.js
  56. +1 −1 lib/coffee-script/repl.js
  57. +1 −1 lib/coffee-script/rewriter.js
  58. +1 −1 lib/coffee-script/scope.js
  59. +1 −1 package.json
  60. +1 −1 src/coffee-script.coffee
@@ -1,5 +1,5 @@
###
-CoffeeScript Compiler v1.3.0
+CoffeeScript Compiler v1.3.1
Released under the MIT License
###
@@ -13,7 +13,7 @@
<span class="nv">content = </span><span class="nx">compile</span> <span class="nx">fs</span><span class="p">.</span><span class="nx">readFileSync</span><span class="p">(</span><span class="nx">filename</span><span class="p">,</span> <span class="s1">&#39;utf8&#39;</span><span class="p">),</span> <span class="p">{</span><span class="nx">filename</span><span class="p">}</span>
<span class="nx">module</span><span class="p">.</span><span class="nx">_compile</span> <span class="nx">content</span><span class="p">,</span> <span class="nx">filename</span>
<span class="k">else</span> <span class="k">if</span> <span class="nx">require</span><span class="p">.</span><span class="nx">registerExtension</span>
- <span class="nx">require</span><span class="p">.</span><span class="nx">registerExtension</span> <span class="s1">&#39;.coffee&#39;</span><span class="p">,</span> <span class="nf">(content) -&gt;</span> <span class="nx">compile</span> <span class="nx">content</span></pre></div> </td> </tr> <tr id="section-3"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-3">&#182;</a> </div> <p>The current CoffeeScript version number.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">exports.VERSION = </span><span class="s1">&#39;1.3.0&#39;</span></pre></div> </td> </tr> <tr id="section-4"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-4">&#182;</a> </div> <p>Words that cannot be used as identifiers in CoffeeScript code</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">exports.RESERVED = </span><span class="nx">RESERVED</span></pre></div> </td> </tr> <tr id="section-5"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-5">&#182;</a> </div> <p>Expose helpers for testing.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">exports.helpers = </span><span class="nx">require</span> <span class="s1">&#39;./helpers&#39;</span></pre></div> </td> </tr> <tr id="section-6"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-6">&#182;</a> </div> <p>Compile a string of CoffeeScript code to JavaScript, using the Coffee/Jison
+ <span class="nx">require</span><span class="p">.</span><span class="nx">registerExtension</span> <span class="s1">&#39;.coffee&#39;</span><span class="p">,</span> <span class="nf">(content) -&gt;</span> <span class="nx">compile</span> <span class="nx">content</span></pre></div> </td> </tr> <tr id="section-3"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-3">&#182;</a> </div> <p>The current CoffeeScript version number.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">exports.VERSION = </span><span class="s1">&#39;1.3.1&#39;</span></pre></div> </td> </tr> <tr id="section-4"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-4">&#182;</a> </div> <p>Words that cannot be used as identifiers in CoffeeScript code</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">exports.RESERVED = </span><span class="nx">RESERVED</span></pre></div> </td> </tr> <tr id="section-5"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-5">&#182;</a> </div> <p>Expose helpers for testing.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">exports.helpers = </span><span class="nx">require</span> <span class="s1">&#39;./helpers&#39;</span></pre></div> </td> </tr> <tr id="section-6"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-6">&#182;</a> </div> <p>Compile a string of CoffeeScript code to JavaScript, using the Coffee/Jison
compiler.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">exports.compile = compile = </span><span class="nf">(code, options = {}) -&gt;</span>
<span class="p">{</span><span class="nx">merge</span><span class="p">}</span> <span class="o">=</span> <span class="nx">exports</span><span class="p">.</span><span class="nx">helpers</span>
<span class="k">try</span>
@@ -850,7 +850,8 @@
<span class="k">if</span> <span class="nx">o</span><span class="p">.</span><span class="nx">level</span> <span class="o">&lt;</span> <span class="nx">LEVEL_LIST</span> <span class="k">then</span> <span class="nx">code</span> <span class="k">else</span> <span class="s2">&quot;(#{code})&quot;</span></pre></div> </td> </tr> <tr id="section-96"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-96">&#182;</a> </div> <p>When compiling a conditional assignment, take care to ensure that the
operands are only evaluated once, even though we have to reference them
more than once.</p> </td> <td class="code"> <div class="highlight"><pre> <span class="nv">compileConditional: </span><span class="nf">(o) -&gt;</span>
- <span class="p">[</span><span class="nx">left</span><span class="p">,</span> <span class="nx">right</span><span class="p">]</span> <span class="o">=</span> <span class="nx">@variable</span><span class="p">.</span><span class="nx">cacheReference</span> <span class="nx">o</span></pre></div> </td> </tr> <tr id="section-97"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-97">&#182;</a> </div> <p>Disallow conditional assignment of undefined variables.</p> </td> <td class="code"> <div class="highlight"><pre> <span class="k">if</span> <span class="nx">left</span><span class="p">.</span><span class="nx">base</span> <span class="k">instanceof</span> <span class="nx">Literal</span> <span class="o">and</span> <span class="nx">left</span><span class="p">.</span><span class="nx">base</span><span class="p">.</span><span class="nx">value</span> <span class="o">!=</span> <span class="s2">&quot;this&quot;</span> <span class="o">and</span> <span class="o">not</span> <span class="nx">o</span><span class="p">.</span><span class="nx">scope</span><span class="p">.</span><span class="nx">check</span> <span class="nx">left</span><span class="p">.</span><span class="nx">base</span><span class="p">.</span><span class="nx">value</span>
+ <span class="p">[</span><span class="nx">left</span><span class="p">,</span> <span class="nx">right</span><span class="p">]</span> <span class="o">=</span> <span class="nx">@variable</span><span class="p">.</span><span class="nx">cacheReference</span> <span class="nx">o</span></pre></div> </td> </tr> <tr id="section-97"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-97">&#182;</a> </div> <p>Disallow conditional assignment of undefined variables.</p> </td> <td class="code"> <div class="highlight"><pre> <span class="k">if</span> <span class="o">not</span> <span class="nx">left</span><span class="p">.</span><span class="nx">properties</span><span class="p">.</span><span class="nx">length</span> <span class="o">and</span> <span class="nx">left</span><span class="p">.</span><span class="nx">base</span> <span class="k">instanceof</span> <span class="nx">Literal</span> <span class="o">and</span>
+ <span class="nx">left</span><span class="p">.</span><span class="nx">base</span><span class="p">.</span><span class="nx">value</span> <span class="o">!=</span> <span class="s2">&quot;this&quot;</span> <span class="o">and</span> <span class="o">not</span> <span class="nx">o</span><span class="p">.</span><span class="nx">scope</span><span class="p">.</span><span class="nx">check</span> <span class="nx">left</span><span class="p">.</span><span class="nx">base</span><span class="p">.</span><span class="nx">value</span>
<span class="k">throw</span> <span class="k">new</span> <span class="nb">Error</span> <span class="s2">&quot;the variable \&quot;#{left.base.value}\&quot; can&#39;t be assigned with #{@context} because it has not been defined.&quot;</span>
<span class="k">if</span> <span class="s2">&quot;?&quot;</span> <span class="k">in</span> <span class="nx">@context</span> <span class="k">then</span> <span class="nv">o.isExistentialEquals = </span><span class="kc">true</span>
<span class="k">new</span> <span class="nx">Op</span><span class="p">(</span><span class="nx">@context</span><span class="p">[...</span><span class="o">-</span><span class="mi">1</span><span class="p">],</span> <span class="nx">left</span><span class="p">,</span> <span class="k">new</span> <span class="nx">Assign</span><span class="p">(</span><span class="nx">right</span><span class="p">,</span> <span class="nx">@value</span><span class="p">,</span> <span class="s1">&#39;=&#39;</span><span class="p">)</span> <span class="p">).</span><span class="nx">compile</span> <span class="nx">o</span></pre></div> </td> </tr> <tr id="section-98"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-98">&#182;</a> </div> <p>Compile the assignment from an array splice literal, using JavaScript's
@@ -135,7 +135,7 @@
<p>
<b>Latest Version:</b>
- <a href="http://github.com/jashkenas/coffee-script/tarball/1.3.0">1.3.0</a>
+ <a href="http://github.com/jashkenas/coffee-script/tarball/1.3.1">1.3.1</a>
</p>
<h2>
@@ -1105,7 +1105,7 @@ Expressions
<p>
<b class="header" style="margin-top: 20px;">
- <a href="https://github.com/jashkenas/coffee-script/compare/1.2.0...1.3.0">1.3.0</a>
+ <a href="https://github.com/jashkenas/coffee-script/compare/1.2.0...1.3.1">1.3.1</a>
<span class="timestamp"> &ndash; <small>April 10, 2012</small></span>
</b>
<ul>

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View

Large diffs are not rendered by default.

Oops, something went wrong.
View
@@ -112,7 +112,7 @@
<p>
<b>Latest Version:</b>
- <a href="http://github.com/jashkenas/coffee-script/tarball/1.3.0">1.3.0</a>
+ <a href="http://github.com/jashkenas/coffee-script/tarball/1.3.1">1.3.1</a>
</p>
<h2>
@@ -1998,18 +1998,18 @@ <h2>
are preserved in the generated code.
</p>
<div class='code'><pre class="idle"><span class="Comment"><span class="Comment">###</span></span>
-<span class="Comment">CoffeeScript Compiler v1.3.0</span>
+<span class="Comment">CoffeeScript Compiler v1.3.1</span>
<span class="Comment">Released under the MIT License</span>
<span class="Comment"><span class="Comment">###</span></span>
</pre><pre class="idle"><span class="Comment"><span class="Comment">/*</span></span>
-<span class="Comment">CoffeeScript Compiler v1.3.0</span>
+<span class="Comment">CoffeeScript Compiler v1.3.1</span>
<span class="Comment">Released under the MIT License</span>
<span class="Comment"><span class="Comment">*/</span></span>
-</pre><script>window.example37 = "###\nCoffeeScript Compiler v1.3.0\nReleased under the MIT License\n###\n\n\n"</script><div class='minibutton load' onclick='javascript: loadConsole(example37);'>load</div><br class='clear' /></div>
+</pre><script>window.example37 = "###\nCoffeeScript Compiler v1.3.1\nReleased under the MIT License\n###\n\n\n"</script><div class='minibutton load' onclick='javascript: loadConsole(example37);'>load</div><br class='clear' /></div>
<p>
<span id="regexes" class="bookmark"></span>
@@ -2287,7 +2287,7 @@ <h2>
<p>
<b class="header" style="margin-top: 20px;">
- <a href="https://github.com/jashkenas/coffee-script/compare/1.2.0...1.3.0">1.3.0</a>
+ <a href="https://github.com/jashkenas/coffee-script/compare/1.2.0...1.3.1">1.3.1</a>
<span class="timestamp"> &ndash; <small>April 10, 2012</small></span>
</b>
<ul>

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
Oops, something went wrong.

0 comments on commit 60c9b94

Please sign in to comment.