[proxy] web.archive.org← back | site home | direct (HTTPS) ↗ | proxy home | ◑ dark◐ light
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 .
base repository: jashkenas/coffeescript
base: 2.0.3
head repository: jashkenas/coffeescript
compare: 2.1.0
  • 9 commits
  • 38 files changed
  • 0 comments
  • 2 contributors
Commits on Nov 29, 2017
* Elision

* test

* improvements

* grammar optimization

* cleanup
Commits on Dec 01, 2017
* First attempt at using AppVeyor

* Maybe it doesn't like the leading dot?

* Versions are an array

* Fix tests on Windows: for some reason, Windows requires `coffee` to be executed as `node coffee` (in the context of `spawnSync`, at least)

* Use npm@latest, see if that's less noisy

* Nevermind, only an issue on Node 6

* Better to see the NPM version before npm install
Commits on Dec 03, 2017
)

* fix comment with /// in heregex

* cleanup

* improved pattern for comments in heregex; fixed unescaped hashes in lexer.coffee

* improvements

* refactor RegExp

* cleanup

* Improved RegEx
Commits on Dec 04, 2017
Commits on Dec 09, 2017
* CSX fragments

* regex improvement; tests

* regex improvement

* regex improvement

* bug fix; regex

* Fix style

* Split fragment tests
* Computed property keys

* refactor

* improvements

* refactor tests

* fix comments
Commits on Dec 10, 2017
Commits on Dec 11, 2017
* Changelog for 2.1.0; remove text from objects section that is no longer valid for CS2/ES2015.

* Update packages

* 2.1.0 build

* Update output

* Correct reference to `//` division, per coffeescript6/discuss#39 (comment)
@@ -0,0 +1,27 @@
environment:
matrix:
- nodejs_version: '6'
- nodejs_version: '8'
- nodejs_version: '' # Installs latest.

install:
- ps: Install-Product node $env:nodejs_version
- node --version
- npm --version
- npm install

cache:
- node_modules

test_script:
- node ./bin/cake build:except-parser
- node ./bin/cake build:parser
- node ./bin/cake build:full
- node ./bin/cake build:browser
- node ./bin/cake test
- node ./bin/cake test:browser
- node ./bin/cake test:integrations

build: off

version: "{build}"

Large diffs are not rendered by default.

@@ -1121,7 +1121,7 @@ <h2 id="tokenizers">Tokenizers</h2>

<div class="content"><div class='highlight'><pre> prevChar = <span class="hljs-keyword">if</span> @tokens.length &gt; <span class="hljs-number">0</span> <span class="hljs-keyword">then</span> @tokens[@tokens.length - <span class="hljs-number">1</span>][<span class="hljs-number">0</span>] <span class="hljs-keyword">else</span> <span class="hljs-string">''</span>
<span class="hljs-keyword">if</span> firstChar <span class="hljs-keyword">is</span> <span class="hljs-string">'&lt;'</span>
match = CSX_IDENTIFIER.exec @chunk[<span class="hljs-number">1.</span>..]
match = CSX_IDENTIFIER.exec(@chunk[<span class="hljs-number">1.</span>..]) <span class="hljs-keyword">or</span> CSX_FRAGMENT_IDENTIFIER.exec(@chunk[<span class="hljs-number">1.</span>..])
<span class="hljs-keyword">return</span> <span class="hljs-number">0</span> <span class="hljs-keyword">unless</span> match <span class="hljs-keyword">and</span> (
@csxDepth &gt; <span class="hljs-number">0</span> <span class="hljs-keyword">or</span></pre></div></div>

@@ -1187,8 +1187,8 @@ <h2 id="tokenizers">Tokenizers</h2>
@matchWithInterpolations INSIDE_CSX, <span class="hljs-string">'&gt;'</span>, <span class="hljs-string">'&lt;/'</span>, CSX_INTERPOLATION
@mergeInterpolationTokens tokens, {delimiter: <span class="hljs-string">'"'</span>}, <span class="hljs-function"><span class="hljs-params">(value, i)</span> =&gt;</span>
@formatString value, delimiter: <span class="hljs-string">'&gt;'</span>
match = CSX_IDENTIFIER.exec @chunk[end...]
<span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> match <span class="hljs-keyword">or</span> match[<span class="hljs-number">0</span>] <span class="hljs-keyword">isnt</span> csxTag.name
match = CSX_IDENTIFIER.exec(@chunk[end...]) <span class="hljs-keyword">or</span> CSX_FRAGMENT_IDENTIFIER.exec(@chunk[end...])
<span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> match <span class="hljs-keyword">or</span> match[<span class="hljs-number">1</span>] <span class="hljs-keyword">isnt</span> csxTag.name
@error <span class="hljs-string">"expected corresponding CSX closing tag for <span class="hljs-subst">#{csxTag.name}</span>"</span>,
csxTag.origin[<span class="hljs-number">2</span>]
afterTag = end + csxTag.name.length
@@ -2458,6 +2458,23 @@ <h2 id="constants">Constants</h2>
CSX_IDENTIFIER = <span class="hljs-regexp">/// ^
(?![\d&lt;]) <span class="hljs-comment"># Must not start with `&lt;`.</span>
( (?: (?!\s)[\.\-$\w\x7f-\uffff] )+ ) <span class="hljs-comment"># Like `IDENTIFIER`, but includes `-`s and `.`s.</span>
///</span></pre></div></div>

</li>


<li id="section-98">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-98">&#182;</a>
</div>
<p>Fragment: &lt;&gt;&lt;/&gt;</p>

</div>

<div class="content"><div class='highlight'><pre>CSX_FRAGMENT_IDENTIFIER = <span class="hljs-regexp">/// ^
()&gt; <span class="hljs-comment"># Ends immediately with `&gt;`.</span>
///</span>

CSX_ATTRIBUTE = <span class="hljs-regexp">/// ^
@@ -2497,11 +2514,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-98">
<li id="section-99">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-98">&#182;</a>
<a class="pilcrow" href="#section-99">&#182;</a>
</div>
<p>String-matching-regexes.</p>

@@ -2535,11 +2552,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-99">
<li id="section-100">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-99">&#182;</a>
<a class="pilcrow" href="#section-100">&#182;</a>
</div>
<p>Regex-matching-regexes.</p>

@@ -2558,7 +2575,86 @@ <h2 id="constants">Constants</h2>
REGEX_FLAGS = <span class="hljs-regexp">/^\w*/</span>
VALID_FLAGS = <span class="hljs-regexp">/^(?!.*(.).*\1)[imguy]*$/</span>

HEREGEX = <span class="hljs-regexp">/// ^(?: [^\\/<span class="hljs-comment">#] | \\[\s\S] | /(?!//) | \#(?!\{) )* ///</span>
HEREGEX = <span class="hljs-regexp">/// ^
(?:
</span></pre></div></div>

</li>


<li id="section-101">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-101">&#182;</a>
</div>
<p>Match any character, except those that need special handling below.</p>

</div>

<div class="content"><div class='highlight'><pre> [^\\/<span class="hljs-comment">#\s]</span></pre></div></div>

</li>


<li id="section-102">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-102">&#182;</a>
</div>
<p>Match <code>\</code> followed by any character.</p>

</div>

<div class="content"><div class='highlight'><pre> | \\[\s\S]</pre></div></div>

</li>


<li id="section-103">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-103">&#182;</a>
</div>
<p>Match any <code>/</code> except <code>///</code>.</p>

</div>

<div class="content"><div class='highlight'><pre> | <span class="hljs-regexp">/(?!/</span>/)</pre></div></div>

</li>


<li id="section-104">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-104">&#182;</a>
</div>
<p>Match <code>#</code> which is not part of interpolation, e.g. <code>#{}</code>.</p>

</div>

<div class="content"><div class='highlight'><pre> | \<span class="hljs-comment">#(?!\{)</span></pre></div></div>

</li>


<li id="section-105">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-105">&#182;</a>
</div>
<p>Comments consume everything until the end of the line, including <code>///</code>.</p>

</div>

<div class="content"><div class='highlight'><pre> | \s+(?:<span class="hljs-comment">#(?!\{).*)?</span>
)*
<span class="hljs-regexp">///

HEREGEX_OMIT = ///</span>
((?:\\\\)+) <span class="hljs-comment"># Consume (and preserve) an even number of backslashes.</span>
@@ -2573,11 +2669,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-100">
<li id="section-106">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-100">&#182;</a>
<a class="pilcrow" href="#section-106">&#182;</a>
</div>
<p>Other regexes.</p>

@@ -2620,11 +2716,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-101">
<li id="section-107">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-101">&#182;</a>
<a class="pilcrow" href="#section-107">&#182;</a>
</div>
<p>Compound assignment tokens.</p>

@@ -2638,11 +2734,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-102">
<li id="section-108">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-102">&#182;</a>
<a class="pilcrow" href="#section-108">&#182;</a>
</div>
<p>Unary tokens.</p>

@@ -2655,11 +2751,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-103">
<li id="section-109">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-103">&#182;</a>
<a class="pilcrow" href="#section-109">&#182;</a>
</div>
<p>Bit-shifting tokens.</p>

@@ -2670,11 +2766,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-104">
<li id="section-110">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-104">&#182;</a>
<a class="pilcrow" href="#section-110">&#182;</a>
</div>
<p>Comparison tokens.</p>

@@ -2685,11 +2781,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-105">
<li id="section-111">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-105">&#182;</a>
<a class="pilcrow" href="#section-111">&#182;</a>
</div>
<p>Mathematical tokens.</p>

@@ -2700,11 +2796,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-106">
<li id="section-112">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-106">&#182;</a>
<a class="pilcrow" href="#section-112">&#182;</a>
</div>
<p>Relational tokens that are negatable with <code>not</code> prefix.</p>

@@ -2715,11 +2811,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-107">
<li id="section-113">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-107">&#182;</a>
<a class="pilcrow" href="#section-113">&#182;</a>
</div>
<p>Boolean tokens.</p>

@@ -2730,11 +2826,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-108">
<li id="section-114">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-108">&#182;</a>
<a class="pilcrow" href="#section-114">&#182;</a>
</div>
<p>Tokens which could legitimately be invoked or indexed. An opening
parentheses or bracket following these tokens will be recorded as the start
@@ -2751,11 +2847,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-109">
<li id="section-115">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-109">&#182;</a>
<a class="pilcrow" href="#section-115">&#182;</a>
</div>
<p>Tokens which can be the left-hand side of a less-than comparison, i.e. <code>a&lt;b</code>.</p>

@@ -2766,11 +2862,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-110">
<li id="section-116">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-110">&#182;</a>
<a class="pilcrow" href="#section-116">&#182;</a>
</div>
<p>Tokens which a regular expression will never immediately follow (except spaced
CALLABLEs in some cases), but which a division operator can.</p>
@@ -2783,11 +2879,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-111">
<li id="section-117">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-111">&#182;</a>
<a class="pilcrow" href="#section-117">&#182;</a>
</div>
<p>Tokens that, when immediately preceding a <code>WHEN</code>, indicate that the <code>WHEN</code>
occurs at the start of a line. We disambiguate these from trailing whens to
@@ -2800,11 +2896,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-112">
<li id="section-118">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-112">&#182;</a>
<a class="pilcrow" href="#section-118">&#182;</a>
</div>
<p>Additional indent in front of these is ignored.</p>

@@ -2815,11 +2911,11 @@ <h2 id="constants">Constants</h2>
</li>


<li id="section-113">
<li id="section-119">
<div class="annotation">

<div class="pilwrap ">
<a class="pilcrow" href="#section-113">&#182;</a>
<a class="pilcrow" href="#section-119">&#182;</a>
</div>
<p>Tokens that, when appearing at the end of a line, suppress a following TERMINATOR/INDENT token</p>

No commit comments for this range