Skip to content

Instantly share code, notes, and snippets.

@jonschlinkert
Created October 6, 2016 11:22
Show Gist options
  • Save jonschlinkert/528fe3ca9a6d0d2b64200e90c233aae2 to your computer and use it in GitHub Desktop.
Save jonschlinkert/528fe3ca9a6d0d2b64200e90c233aae2 to your computer and use it in GitHub Desktop.
[07:21:37] Using gulpfile ~/dev/micromatch/braces-dev/gulpfile.js
[07:21:37] Starting 'test'...
compiler
✓ should compile: 0{1..9} {10..20}
✓ should compile: \{a,b,c,d,e}
✓ should compile: a${b}c
✓ should compile: a/\{b,c,d,{x,y}}{e,f\}/g
✓ should compile: a/\{b,c,d\}\{e,f\}/g
✓ should compile: a/\{b,c,d\}\{e,f}/g
✓ should compile: a/\{b,c,d\}{e,f}/g
✓ should compile: a/\{b,c,d{x,y}}{e,f\}/g
✓ should compile: a/\{b,c,d}{e,f\}/g
✓ should compile: a/\{b,c,d}{e,f}/g
✓ should compile: a/\{x,y}/cde
✓ should compile: a/\{{b,c}{e,f}/g
✓ should compile: a/\{{b,c}{e,f}\}/g
✓ should compile: a/\{{b,c}{e,f}}/g
✓ should compile: a/b/c/{x,y\}
✓ should compile: a/b/c{d}e
✓ should compile: a/b/{b,c,{d,e{f,g},{w,x}/{y,z}}}/h/i
✓ should compile: a/{${b},c}/d
✓ should compile: a/{b,c,d}{e,f}/g
✓ should compile: a/{b,c\,d}{e,f}/g
✓ should compile: a/{b,c\}}{e,f}/g
✓ should compile: a/{b,c}
✓ should compile: a/{b,c}d{e,f}/g
✓ should compile: a/{b,c}{e,f}/g
✓ should compile: a/{b,c}{e,f}{g,h,i}/k
✓ should compile: a/{b,{c,d},e}/f
✓ should compile: a/{b,{c,d}/{e,f},g}/h
✓ should compile: a/{b{c,d},e{f,g}h{i,j}}/k
✓ should compile: a/{b{c,d},e}/f
✓ should compile: a/{b{c,d}e{f,g}h{i,j}}/k
✓ should compile: a/{b{c,d}e{f,g},h{i,j}}/k
✓ should compile: a/{x,y}/{1..5}c{d,e}f.{md,txt}
✓ should compile: a/{x,z}{b,{c,d}/{e,f},g}/h
✓ should compile: a/{x,{1..5},y}/c{d}e
✓ should compile: a/{{a,b}/{c,d}}/z
✓ should compile: a/{{b,c}/{d,e}}
✓ should compile: a/{{b,c}/{d,e}}/f
✓ should compile: abc/${ddd}/xyz
✓ should compile: abcd{efgh
✓ should compile: a{ ,c{d, },h}
✓ should compile: a{ ,c{d, },h}x
✓ should compile: a{0..3}d
✓ should compile: a{b{c{d,e}f{x,y{{g}h
✓ should compile: a{b}c
✓ should compile: foo {1,2} bar
✓ should compile: x{10..1}y
✓ should compile: x{3..3}y
✓ should compile: { }
✓ should compile: {
✓ should compile: {0..10,braces}
✓ should compile: {10..1}
✓ should compile: {3..3}
✓ should compile: {5..8}
✓ should compile: {9..-4}
✓ should compile: {a,b,{c,d},e}
✓ should compile: {a,b,{c,d}e}
✓ should compile: {a,b,{c,d}}
✓ should compile: {a,b{c,d}}
✓ should compile: {a,b}/{c,d}
✓ should compile: {a,b}c,d\}
✓ should compile: {a,b\}c,d}
✓ should compile: {a,b}{c,d}
✓ should compile: {abc}
✓ should compile: {b{c,d},e}
✓ should compile: {b{c,d},e}/f
✓ should compile: {x,y,\{a,b,c\}}
✓ should compile: {x,y,{a,b,c\}}
✓ should compile: {x,y,{abc},trie}
✓ should compile: x,y,{abc},trie
✓ should compile: {x\,y,\{abc\},trie}
✓ should compile: {{0..10},braces}
✓ should compile: {{a,b},{c,d}}
✓ should compile: {{a,b}/{c,d}}
✓ should compile: {{a,b}/{c,d}}/z
✓ should compile: {}
✓ should compile: }
✓ should compile: {generate,{assemble,update,verb}{file,-generate-*},generator}.js
✓ should compile: **/{foo,bar}.js
✓ should compile: **/{1..5}/a.js
✓ should compile: **/{a,b,c}/*.js
✓ should compile: **/{a,b,*}/*.js
✓ should compile: **/{**,b,*}/*.js
✓ should compile: /usr/{ucb/{ex,edit},lib/{ex,how_ex}}
✓ should compile: ff{c,b,a}
✓ should compile: f{d,e,f}g
✓ should compile: x{{0..10},braces}y
✓ should compile: {a,b,c}
✓ should compile: {braces,{0..10}}
✓ should compile: {l,n,m}xyz
✓ should compile: {{0..10},braces}
✓ should compile: {{1..10..2},braces}
✓ should compile: {{1..10},braces}
✓ should compile: a/{a,b}/{c,d}/e
✓ should compile: a{b,c}d{e,f}g
✓ should compile: a/{x,y}/c{d,e}f.{md,txt}
✓ should compile: {a,b}{{a,b},a,b}
✓ should compile: /usr/{ucb/{ex,edit},lib/{ex,how_ex}}
✓ should compile: a{b,c{d,e}f}g
✓ should compile: a{{x,y},z}b
✓ should compile: f{x,y{g,z}}h
✓ should compile: a{b,c{d,e},h}x/z
✓ should compile: a{b,c{d,e},h}x{y,z}
✓ should compile: a{b,c{d,e},{f,g}h}x{y,z}
✓ should compile: {0..10,braces}
✓ should compile: {1..10,braces}
✓ should compile: \{a,b,c,d,e}
✓ should compile: a/b/c/{x,y\}
✓ should compile: a/\{x,y}/cde
✓ should compile: abcd{efgh
✓ should compile: {abc}
✓ should compile: {x,y,\{a,b,c\}}
✓ should compile: {x,y,{a,b,c\}}
✓ should compile: {x,y,{abc},trie}
✓ should compile: {x\,y,\{abc\},trie}
✓ should compile: { }
✓ should compile: {
✓ should compile: {}
✓ should compile: }
✓ should compile: a{b}c
✓ should compile: a/b/c{d}e
✓ should compile: {a,b}c,d}
✓ should compile: abc/${ddd}/xyz
✓ should compile: a${b}c
✓ should compile: a/{${b},c}/d
✓ should compile: a${b,d}/{foo,bar}c
✓ should compile: a{b\,c\,d}e
✓ should compile: a{b\,c}d
✓ should compile: {abc\,def}
✓ should compile: {abc\,def,ghi}
✓ should compile: a/{b,c}/{x\,y}/d/e
✓ should compile: {a,b\}c,d}
✓ should compile: \{a,b,c,d,e}
✓ should compile: a/{z,\{a,b,c,d,e}/d
✓ should compile: a/\{b,c}/{d,e}/f
✓ should compile: ./\{x,y}/{a..z..3}/
✓ should compile: {x\,y,\{abc\},trie}
✓ should compile: /usr/{ucb/{ex,edit},lib/{ex,how_ex}}
✓ should compile: ff{c,b,a}
✓ should compile: f{d,e,f}g
✓ should compile: x{{0..10},braces}y
✓ should compile: {a,b,c}
✓ should compile: {braces,{0..10}}
✓ should compile: {l,n,m}xyz
✓ should compile: {{0..10},braces}
✓ should compile: {{1..10..2},braces}
✓ should compile: {{1..10},braces}
✓ should compile: a/{a,b}/{c,d}/e
✓ should compile: a{b,c}d{e,f}g
✓ should compile: a/{x,y}/c{d,e}f.{md,txt}
✓ should compile: {a,b}{{a,b},a,b}
✓ should compile: /usr/{ucb/{ex,edit},lib/{ex,how_ex}}
✓ should compile: a{b,c{d,e}f}g
✓ should compile: a{{x,y},z}b
✓ should compile: f{x,y{g,z}}h
✓ should compile: a{b,c{d,e},h}x/z
✓ should compile: a{b,c{d,e},h}x{y,z}
✓ should compile: a{b,c{d,e},{f,g}h}x{y,z}
✓ should compile: a-{b{d,e}}-c
✓ should compile: a/b/{d,e}/*.js
✓ should compile: a/**/c/{d,e}/f*.js
✓ should compile: a/**/c/{d,e}/f*.{md,txt}
✓ should compile: a/b/{d,e,[1-5]}/*.js
✓ should compile: a{b,}c
✓ should compile: a{,b}c
✓ should compile: 0{1..9} {10..20}
✓ should compile: a{ ,c{d, },h}x
✓ should compile: a{ ,c{d, },h}
✓ should compile: /Users/tobiasreich/Sites/aaa/bbb/ccc 2016/src/**/[^_]*.{html,ejs}
✓ should compile: {1.1..2.1}
✓ should compile: {1.1..~2.1}
✓ should compile: {1..0f}
✓ should compile: {1..10..ff}
✓ should compile: {1..10.f}
✓ should compile: {1..10f}
✓ should compile: {1..20..2f}
✓ should compile: {1..20..f2}
✓ should compile: {1..2f..2}
✓ should compile: {1..ff..2}
✓ should compile: {1..ff}
✓ should compile: {1.20..2}
✓ should compile: a-{b{d,e}}-c
✓ should compile: a-{bdef-{g,i}-c
✓ should compile: {"klklkl"}{1,2,3}
✓ should compile: {"x,x"}
✓ should compile: {a-{b,c,d}}
✓ should compile: {a,{a-{b,c,d}}}
✓ should compile: abc{
✓ should compile: {abc{
✓ should compile: {abc
✓ should compile: }abc
✓ should compile: ab{c
✓ should compile: ab{c
✓ should compile: {{a,b}
✓ should compile: {a,b}}
✓ should compile: abcd{efgh
✓ should compile: a{b{c{d,e}f}gh
✓ should compile: a{b{c{d,e}f}g}h
✓ should compile: f{x,y{{g,z}}h}
✓ should compile: z{a,b},c}d
✓ should compile: a{b{c{d,e}f{x,y{{g}h
✓ should compile: f{x,y{{g}h
✓ should compile: f{x,y{{g}}h
✓ should compile: a{b{c{d,e}f{x,y{}g}h
✓ should compile: f{x,y{}g}h
✓ should compile: z{a,b{,c}d
✓ should compile: a{0..3}d
✓ should compile: x{10..1}y
✓ should compile: x{3..3}y
✓ should compile: {1..10}
✓ should compile: {1..3}
✓ should compile: {1..9}
✓ should compile: {10..1}y
✓ should compile: {3..3}
✓ should compile: {5..8}
✓ should compile: {-10..-1}
✓ should compile: {-20..0}
✓ should compile: {0..-5}
✓ should compile: {9..-4}
✓ should compile: 0{1..9}/{10..20}
✓ should compile: 0{a..d}0
✓ should compile: a/{b..d}/e
✓ should compile: {1..f}
✓ should compile: {a..A}
✓ should compile: {A..a}
✓ should compile: {a..e}
✓ should compile: {A..E}
✓ should compile: {a..f}
✓ should compile: {a..z}
✓ should compile: {E..A}
✓ should compile: {f..1}
✓ should compile: {f..a}
✓ should compile: {f..f}
✓ should compile: a/{b..d}/e/{f..h}
✓ should compile: {-10..10}
✓ should compile: {2147483645..2147483649}
✓ should compile: {214748364..2147483649}
✓ should compile: {1..10..1}
✓ should compile: {1..10..2}
✓ should compile: {1..20..20}
✓ should compile: {1..20..20}
✓ should compile: {1..20..20}
✓ should compile: {1..20..2}
✓ should compile: {10..0..2}
✓ should compile: {10..1..2}
✓ should compile: {100..0..5}
✓ should compile: {2..10..1}
✓ should compile: {2..10..2}
✓ should compile: {2..10..3}
✓ should compile: {a..z..2}
✓ should compile: {10..0..-2}
✓ should compile: {-1..-10..-2}
✓ should compile: {-1..-10..2}
✓ should compile: {-10..-2..2}
✓ should compile: {-2..-10..1}
✓ should compile: {-2..-10..2}
✓ should compile: {-2..-10..3}
✓ should compile: {-50..-0..5}
✓ should compile: {-9..9..3}
✓ should compile: {10..1..-2}
✓ should compile: {100..0..-5}
✓ should compile: {a..e..2}
✓ should compile: {E..A..2}
✓ should compile: {a..z..2}
✓ should compile: {z..a..-2}
✓ should compile: {z..a..-2}
✓ should compile: {10..0..2}
✓ should compile: {10..0..-2}
✓ should compile: {-50..-0..5}
✓ should compile: ../{1..3}/../foo
✓ should compile: ../{2..10..2}/../foo
✓ should compile: ../{1..3}/../{a,b,c}/foo
✓ should compile: ./{a..z..3}/
✓ should compile: ./{"x,y"}/{a..z..3}/
✓ should compile: a/{x,y}/{1..5}c{d,e}f.{md,txt}
✓ should compile: a/{x,{1..5},y}/c{d}e
optimized
1) should compile: 0{1..9} {10..20}
✓ should compile: {a,b,c,d,e}
✓ should compile: \{a,b,c,d,e}
✓ should compile: a${b}c
✓ should compile: a/\{b,c,d,{x,y}}{e,f\}/g
✓ should compile: a/\{b,c,d\}\{e,f\}/g
✓ should compile: a/\{b,c,d\}\{e,f}/g
✓ should compile: a/\{b,c,d\}{e,f}/g
✓ should compile: a/\{b,c,d{x,y}}{e,f\}/g
✓ should compile: a/\{b,c,d}{e,f\}/g
✓ should compile: a/\{b,c,d}{e,f}/g
✓ should compile: a/\{x,y}/cde
✓ should compile: a/\{{b,c}{e,f}/g
✓ should compile: a/\{{b,c}{e,f}\}/g
✓ should compile: a/\{{b,c}{e,f}}/g
✓ should compile: a/b/c/{x,y\}
✓ should compile: a/b/c{d}e
✓ should compile: a/b/{b,c,{d,e{f,g},{w,x}/{y,z}}}/h/i
✓ should compile: a/{${b},c}/d
✓ should compile: a/{b,c}}{e,f}/g
✓ should compile: a/{b,c\,d}{e,f}/g
✓ should compile: a/{b,c\}}{e,f}/g
✓ should compile: a/{b,c}
✓ should compile: a/{b,c}d{e,f}/g
✓ should compile: a/{b,c}{e,f}/g
✓ should compile: a/{b,c}{e,f}{g,h,i}/k
✓ should compile: a/{b,{c,d},e}/f
✓ should compile: a/{b,{c,d}/{e,f},g}/h
✓ should compile: a/{b{c,d},e{f,g}h{i,j}}/k
✓ should compile: a/{b{c,d},e}/f
✓ should compile: a/{b{c,d}e{f,g}h{i,j}}/k
✓ should compile: a/{b{c,d}e{f,g},h{i,j}}/k
2) should compile: a/{x,y}/{1..5}c{d,e}f.{md,txt}
✓ should compile: a/{x,z}{b,{c,d}/{e,f},g}/h
3) should compile: a/{x,{1..5},y}/c{d}e
✓ should compile: a/{{a,b}/{c,d}}/z
✓ should compile: a/{{b,c}/{d,e}}
✓ should compile: a/{{b,c}/{d,e}}/f
✓ should compile: abc/${ddd}/xyz
✓ should compile: abcd{efgh
✓ should compile: a{ ,c{d, },h}
✓ should compile: a{ ,c{d, },h}x
4) should compile: a{0..3}d
✓ should compile: a{b{c{d,e}f{x,y{{g}h
✓ should compile: a{b}c
✓ should compile: foo {1,2} bar
5) should compile: x{10..1}y
✓ should compile: x{3..3}y
✓ should compile: { }
✓ should compile: {
✓ should compile: {0..10,braces}
✓ should compile: {1..0f}
✓ should compile: {1..10,braces}
✓ should compile: {1..10..ff}
✓ should compile: {1..10.f}
✓ should compile: {1..10f}
6) should compile: {1..10}
✓ should compile: {1..20..2f}
✓ should compile: {1..20..f2}
✓ should compile: {1..2f..2}
7) should compile: {1..3}
8) should compile: {1..9}
✓ should compile: {1..ff}
✓ should compile: {1.20..2}
9) should compile: {10..1}
10) should compile: {214748364..2147483649}
11) should compile: {2147483645..2147483649}
✓ should compile: {3..3}
12) should compile: {5..8}
13) should compile: {9..-4}
✓ should compile: {a,b,{c,d},e}
✓ should compile: {a,b,{c,d}e}
✓ should compile: {a,b,{c,d}}
✓ should compile: {a,b{c,d}}
✓ should compile: {a,b}/{c,d}
✓ should compile: {a,b}{c,d}
14) should compile: {{0..10},braces}
✓ should compile: {{a,b},{c,d}}
✓ should compile: {{a,b}/{c,d}}
✓ should compile: {{a,b}/{c,d}}/z
✓ should compile: {}
✓ should compile: }
✓ should compile: {generate,{assemble,update,verb}{file,-generate-*},generator}.js
✓ should compile: **/{foo,bar}.js
15) should compile: **/{1..5}/a.js
✓ should compile: **/{a,b,c}/*.js
✓ should compile: **/{a,b,*}/*.js
✓ should compile: **/{**,b,*}/*.js
✓ should compile: /usr/{ucb/{ex,edit},lib/{ex,how_ex}}
✓ should compile: ff{c,b,a}
✓ should compile: f{d,e,f}g
16) should compile: x{{0..10},braces}y
17) should compile: {1..10}
✓ should compile: {a,b,c}
18) should compile: {braces,{0..10}}
✓ should compile: {l,n,m}xyz
19) should compile: {{0..10},braces}
✓ should compile: {{1..10..2},braces}
20) should compile: {{1..10},braces}
✓ should compile: a/{a,b}/{c,d}/e
✓ should compile: a{b,c}d{e,f}g
✓ should compile: a/{x,y}/c{d,e}f.{md,txt}
✓ should compile: {a,b}{{a,b},a,b}
✓ should compile: /usr/{ucb/{ex,edit},lib/{ex,how_ex}}
✓ should compile: a{b,c{d,e}f}g
✓ should compile: a{{x,y},z}b
✓ should compile: f{x,y{g,z}}h
✓ should compile: a{b,c{d,e},h}x/z
✓ should compile: a{b,c{d,e},h}x{y,z}
✓ should compile: a{b,c{d,e},{f,g}h}x{y,z}
✓ should compile: {0..10,braces}
✓ should compile: {1..10,braces}
✓ should compile: \{a,b,c,d,e}
✓ should compile: a/b/c/{x,y\}
✓ should compile: a/\{x,y}/cde
✓ should compile: abcd{efgh
✓ should compile: \{abc\}
✓ should compile: {x,y,\{a,b,c\}}
✓ should compile: {x,y,{a,b,c\}}
✓ should compile: {x\,y,\{abc\},trie}
✓ should compile: {x,y,{abc},trie}
✓ should compile: x,y,{abc},trie
✓ should compile: {b{c,d},e}
✓ should compile: {b{c,d},e}/f
✓ should compile: {abc}
✓ should compile: { }
✓ should compile: {
✓ should compile: {}
✓ should compile: }
✓ should compile: a{b}c
✓ should compile: a/b/c{d}e
✓ should compile: {a,b}c,d}
✓ should compile: a,b,c,d}
✓ should compile: abc/${ddd}/xyz
✓ should compile: a${b}c
✓ should compile: a/{${b},c}/d
✓ should compile: a${b,d}/{foo,bar}c
✓ should compile: a{b\,c\,d}e
✓ should compile: a{b\,c}d
✓ should compile: {abc\,def}
✓ should compile: {abc\,def,ghi}
✓ should compile: a/{b,c}/{x\,y}/d/e
✓ should compile: {a,b\}c,d}
✓ should compile: \{a,b,c,d,e}
✓ should compile: a/{z,\{a,b,c,d,e}/d
✓ should compile: a/\{b,c}/{d,e}/f
✓ should compile: ./\{x,y}/{a..z..3}/
✓ should compile: {x\,y,\{abc\},trie}
✓ should compile: /usr/{ucb/{ex,edit},lib/{ex,how_ex}}
✓ should compile: ff{c,b,a}
✓ should compile: f{d,e,f}g
21) should compile: x{{0..10},braces}y
22) should compile: {1..10}
✓ should compile: {a,b,c}
23) should compile: {braces,{0..10}}
✓ should compile: {l,n,m}xyz
24) should compile: {{0..10},braces}
✓ should compile: {{1..10..2},braces}
25) should compile: {{1..10},braces}
✓ should compile: a/{a,b}/{c,d}/e
✓ should compile: a{b,c}d{e,f}g
✓ should compile: a/{x,y}/c{d,e}f.{md,txt}
✓ should compile: {a,b}{{a,b},a,b}
✓ should compile: /usr/{ucb/{ex,edit},lib/{ex,how_ex}}
✓ should compile: a{b,c{d,e}f}g
✓ should compile: a{{x,y},z}b
✓ should compile: f{x,y{g,z}}h
✓ should compile: a{b,c{d,e},h}x/z
✓ should compile: a{b,c{d,e},h}x{y,z}
✓ should compile: a{b,c{d,e},{f,g}h}x{y,z}
✓ should compile: a-{b{d,e}}-c
✓ should compile: a/b/{d,e}/*.js
✓ should compile: a/**/c/{d,e}/f*.js
✓ should compile: a/**/c/{d,e}/f*.{md,txt}
✓ should compile: a{b,}c
✓ should compile: a{,b}c
✓ should compile: foo {1,2} bar
26) should compile: 0{1..9} {10..20}
✓ should compile: a{ ,c{d, },h}x
✓ should compile: a{ ,c{d, },h}
✓ should compile: /Users/tobiasreich/Sites/aaa/bbb/ccc 2016/src/**/[^_]*.{html,ejs}
✓ should compile: {1.1..2.1}
✓ should compile: {1.1..~2.1}
✓ should compile: {1..0f}
✓ should compile: {1..10..ff}
✓ should compile: {1..10.f}
✓ should compile: {1..10f}
✓ should compile: {1..20..2f}
✓ should compile: {1..20..f2}
✓ should compile: {1..2f..2}
✓ should compile: {1..ff..2}
✓ should compile: {1..ff}
✓ should compile: {1.20..2}
✓ should compile: a-{b{d,e}}-c
✓ should compile: a-{bdef-{g,i}-c
✓ should compile: {"klklkl"}{1,2,3}
✓ should compile: {"x,x"}
✓ should compile: {a-{b,c,d}}
✓ should compile: {a,{a-{b,c,d}}}
✓ should compile: a-{bdef-{g,i}-c
✓ should compile: abc{
✓ should compile: {abc{
✓ should compile: {abc
✓ should compile: }abc
✓ should compile: ab{c
✓ should compile: ab{c
✓ should compile: {{a,b}
✓ should compile: {a,b}}
✓ should compile: abcd{efgh
✓ should compile: a{b{c{d,e}f}gh
✓ should compile: a{b{c{d,e}f}g}h
✓ should compile: f{x,y{{g,z}}h}
✓ should compile: z{a,b},c}d
✓ should compile: a{b{c{d,e}f{x,y{{g}h
✓ should compile: f{x,y{{g}h
✓ should compile: f{x,y{{g}}h
✓ should compile: a{b{c{d,e}f{x,y{}g}h
✓ should compile: f{x,y{}g}h
✓ should compile: z{a,b{,c}d
27) should compile: a{0..3}d
28) should compile: x{10..1}y
✓ should compile: x{3..3}y
29) should compile: {1..10}
30) should compile: {1..3}
31) should compile: {1..9}
32) should compile: {10..1}
33) should compile: {10..1}y
✓ should compile: {3..3}
34) should compile: {5..8}
35) should compile: {-10..-1}
36) should compile: {-20..0}
37) should compile: {0..-5}
38) should compile: {9..-4}
39) should compile: 0{1..9}/{10..20}
✓ should compile: 0{a..d}0
✓ should compile: a/{b..d}/e
✓ should compile: {1..f}
✓ should compile: {a..A}
✓ should compile: {A..a}
✓ should compile: {a..e}
✓ should compile: {A..E}
✓ should compile: {a..f}
✓ should compile: {a..z}
✓ should compile: {E..A}
✓ should compile: {f..1}
✓ should compile: {f..a}
✓ should compile: {f..f}
✓ should compile: a/{b..d}/e/{f..h}
40) should compile: {-10..10}
41) should compile: {2147483645..2147483649}
42) should compile: {214748364..2147483649}
43) should compile: {1..10..1}
✓ should compile: {1..10..2}
✓ should compile: {1..20..20}
✓ should compile: {1..20..2}
✓ should compile: {10..0..2}
✓ should compile: {10..1..2}
✓ should compile: {100..0..5}
44) should compile: {2..10..1}
✓ should compile: {2..10..2}
✓ should compile: {2..10..3}
✓ should compile: {a..z..2}
✓ should compile: {10..0..-2}
✓ should compile: {-1..-10..-2}
✓ should compile: {-1..-10..2}
✓ should compile: {-10..-2..2}
45) should compile: {-2..-10..1}
✓ should compile: {-2..-10..2}
✓ should compile: {-2..-10..3}
✓ should compile: {-50..-0..5}
✓ should compile: {-9..9..3}
✓ should compile: {10..1..-2}
✓ should compile: {100..0..-5}
✓ should compile: {a..e..2}
✓ should compile: {E..A..2}
✓ should compile: {a..z..2}
✓ should compile: {z..a..-2}
✓ should compile: {z..a..-2}
✓ should compile: {10..0..2}
✓ should compile: {10..0..-2}
✓ should compile: {-50..-0..5}
46) should compile: ../{1..3}/../foo
✓ should compile: ../{2..10..2}/../foo
47) should compile: ../{1..3}/../{a,b,c}/foo
✓ should compile: ./{a..z..3}/
✓ should compile: ./{"x,y"}/{a..z..3}/
48) should compile: a/{x,y}/{1..5}c{d,e}f.{md,txt}
49) should compile: a/{x,{1..5},y}/c{d}e
optimized
sets
invalid sets
✓ should handle invalid sets:
escaping
✓ should not expand escaped braces
✓ should handle spaces
✓ should handle empty braces
✓ should escape braces when only one value is defined
✓ should escape closing braces when open is not defined
✓ should not expand braces in sets with es6/bash-like variables
✓ should not expand escaped commas.
✓ should return sets with escaped commas
✓ should not expand escaped braces.
✓ should not expand escaped braces or commas.
set expansion
✓ should support sequence brace operators
✓ should support sequence braces with leading characters
✓ should support sequence braces with trailing characters
✓ should support sequence braces with trailing characters
✓ should support nested sequence braces with trailing characters
✓ should expand multiple sets
✓ should expand nested sets
✓ should expand with globs.
commas
✓ should work with leading and trailing commas.
spaces
✓ should handle spaces
ranges
escaping / invalid ranges
✓ should not try to expand ranges with decimals
✓ should escape invalid ranges:
✓ weirdly-formed brace expansions -- fixed in post-bash-3.1
✓ should not expand quoted strings.
✓ should escaped outer braces in nested non-sets
✓ should escape imbalanced braces
positive numeric ranges
✓ should expand numeric ranges
negative ranges
✓ should expand ranges with negative numbers
alphabetical ranges
✓ should expand alphabetical ranges
✓ should expand multiple ranges:
combo
✓ should expand numerical ranges - positive and negative
large numbers
50) should expand large numbers
steps > positive ranges
✓ should expand ranges using steps:
✓ should expand positive ranges with negative steps:
steps > negative ranges
✓ should expand negative ranges using steps:
steps > alphabetical ranges
✓ should expand alpha ranges with steps
✓ should expand alpha ranges with negative steps
padding
✓ unwanted zero-padding -- fixed post-bash-4.0
integration
✓ should work with dots in file paths
✓ should expand a complex combination of ranges and sets:
✓ should expand complex sets and ranges in `bash` mode:
optimized
sets
invalid sets
✓ should handle invalid sets:
escaping
✓ should not expand escaped braces
✓ should handle spaces
✓ should handle empty braces
✓ should escape braces when only one value is defined
✓ should not expand braces in sets with es6/bash-like variables
✓ should not expand escaped commas.
✓ should return sets with escaped commas
✓ should not expand escaped braces.
✓ should not expand escaped braces or commas.
set expansion
51) should support sequence brace operators
✓ should expand multiple sets
✓ should expand nested sets
✓ should expand not modify non-brace characters
commas
✓ should work with leading and trailing commas.
spaces
52) should handle spaces
ranges
escaping / invalid ranges
✓ should not try to expand ranges with decimals
✓ should escape invalid ranges:
✓ weirdly-formed brace expansions -- fixed in post-bash-3.1
✓ should not expand quoted strings.
✓ should escaped outer braces in nested non-sets
✓ should escape imbalanced braces
positive numeric ranges
53) should expand numeric ranges
negative ranges
54) should expand ranges with negative numbers
alphabetical ranges
55) should expand alphabetical ranges
✓ should expand multiple ranges:
combo
56) should expand numerical ranges - positive and negative
large numbers
57) should expand large numbers
steps > positive ranges
58) should expand ranges using steps:
✓ should expand positive ranges with negative steps:
steps > negative ranges
59) should expand negative ranges using steps:
steps > alphabetical ranges
✓ should expand alpha ranges with steps
✓ should expand alpha ranges with negative steps
padding
✓ unwanted zero-padding -- fixed post-bash-4.0
integration
60) should work with dots in file paths
61) should expand a complex combination of ranges and sets:
62) should expand complex sets and ranges in `bash` mode:
options
expand:
✓ should expand braces when `options.expand` is true
optimize:
✓ should optimize braces when `options.optimize` is true
quantifiers:
✓ should not expand regex quantifiers when `options.quantifiers` is true
✓ should expand non-quantifiers when `options.quantifiers` is true
584 passing (8s)
62 failing
1) optimized should compile: 0{1..9} {10..20}:
AssertionError: 0{1..9} {10..20}
"['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }) (1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['0([1-9]) (1[0-9]|20)']"
+ expected - actual
-['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }) (1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['0([1-9]) (1[0-9]|20)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
2) optimized should compile: a/{x,y}/{1..5}c{d,e}f.{md,txt}:
AssertionError: a/{x,y}/{1..5}c{d,e}f.{md,txt}
"['a/(x|y)/([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })c(d|e)f.(md|txt)']" !== "['a/(x|y)/([1-5])c(d|e)f.(md|txt)']"
+ expected - actual
-['a/(x|y)/([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })c(d|e)f.(md|txt)']
+['a/(x|y)/([1-5])c(d|e)f.(md|txt)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
3) optimized should compile: a/{x,{1..5},y}/c{d}e:
AssertionError: a/{x,{1..5},y}/c{d}e
"['a/(x|([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|y)/c{d}e']" !== "['a/(x|([1-5])|y)/c{d}e']"
+ expected - actual
-['a/(x|([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|y)/c{d}e']
+['a/(x|([1-5])|y)/c{d}e']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
4) optimized should compile: a{0..3}d:
AssertionError: a{0..3}d
"['a([0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })d']" !== "['a([0-3])d']"
+ expected - actual
-['a([0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })d']
+['a([0-3])d']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
5) optimized should compile: x{10..1}y:
AssertionError: x{10..1}y
"['x([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })y']" !== "['x([1-9]|10)y']"
+ expected - actual
-['x([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })y']
+['x([1-9]|10)y']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
6) optimized should compile: {1..10}:
AssertionError: {1..10}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9]|10)']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
7) optimized should compile: {1..3}:
AssertionError: {1..3}
"['([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-3])']"
+ expected - actual
-['([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-3])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
8) optimized should compile: {1..9}:
AssertionError: {1..9}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9])']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
9) optimized should compile: {10..1}:
AssertionError: {10..1}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9]|10)']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
10) optimized should compile: {214748364..2147483649}:
AssertionError: {214748364..2147483649}
"['(21474836[4-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|2147483[7-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|214748[4-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{2}|214749function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{3}|2147[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{4}|214[8-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{5}|21[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{6}|2[2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{7}|[3-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{8}|1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{9}|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{8}|21[0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{7}|214[0-6]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{6}|2147[0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{5}|21474[0-7]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{4}|214748[0-2]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{3}|2147483[0-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{2}|21474836[0-4]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']" !== "['(21474836[4-9]|2147483[7-9][0-9]|214748[4-9][0-9]{2}|214749[0-9]{3}|2147[5-9][0-9]{4}|214[8-9][0-9]{5}|21[5-9][0-9]{6}|2[2-9][0-9]{7}|[3-9][0-9]{8}|1[0-9]{9}|20[0-9]{8}|21[0-3][0-9]{7}|214[0-6][0-9]{6}|2147[0-3][0-9]{5}|21474[0-7][0-9]{4}|214748[0-2][0-9]{3}|2147483[0-5][0-9]{2}|21474836[0-4][0-9])']"
+ expected - actual
-['(21474836[4-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|2147483[7-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|214748[4-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{2}|214749function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{3}|2147[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{4}|214[8-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{5}|21[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{6}|2[2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{7}|[3-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{8}|1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{9}|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{8}|21[0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{7}|214[0-6]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{6}|2147[0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{5}|21474[0-7]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{4}|214748[0-2]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{3}|2147483[0-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{2}|21474836[0-4]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']
+['(21474836[4-9]|2147483[7-9][0-9]|214748[4-9][0-9]{2}|214749[0-9]{3}|2147[5-9][0-9]{4}|214[8-9][0-9]{5}|21[5-9][0-9]{6}|2[2-9][0-9]{7}|[3-9][0-9]{8}|1[0-9]{9}|20[0-9]{8}|21[0-3][0-9]{7}|214[0-6][0-9]{6}|2147[0-3][0-9]{5}|21474[0-7][0-9]{4}|214748[0-2][0-9]{3}|2147483[0-5][0-9]{2}|21474836[0-4][0-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
11) optimized should compile: {2147483645..2147483649}:
AssertionError: {2147483645..2147483649}
"['(214748364[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(214748364[5-9])']"
+ expected - actual
-['(214748364[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(214748364[5-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
12) optimized should compile: {5..8}:
AssertionError: {5..8}
"['([5-8]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([5-8])']"
+ expected - actual
-['([5-8]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([5-8])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
13) optimized should compile: {9..-4}:
AssertionError: {9..-4}
"['(-[1-4]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']" !== "['(-[1-4]|[0-9])']"
+ expected - actual
-['(-[1-4]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']
+['(-[1-4]|[0-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
14) optimized should compile: {{0..10},braces}:
AssertionError: {{0..10},braces}
"['((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']" !== "['(([0-9]|10)|braces)']"
+ expected - actual
-['((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']
+['(([0-9]|10)|braces)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
15) optimized should compile: **/{1..5}/a.js:
AssertionError: **/{1..5}/a.js
"['**/([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/a.js']" !== "['**/([1-5])/a.js']"
+ expected - actual
-['**/([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/a.js']
+['**/([1-5])/a.js']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
16) optimized should compile: x{{0..10},braces}y:
AssertionError: x{{0..10},braces}y
"['x((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)y']" !== "['x(([0-9]|10)|braces)y']"
+ expected - actual
-['x((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)y']
+['x(([0-9]|10)|braces)y']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
17) optimized should compile: {1..10}:
AssertionError: {1..10}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9]|10)']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
18) optimized should compile: {braces,{0..10}}:
AssertionError: {braces,{0..10}}
"['(braces|(function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }))']" !== "['(braces|([0-9]|10))']"
+ expected - actual
-['(braces|(function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }))']
+['(braces|([0-9]|10))']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
19) optimized should compile: {{0..10},braces}:
AssertionError: {{0..10},braces}
"['((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']" !== "['(([0-9]|10)|braces)']"
+ expected - actual
-['((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']
+['(([0-9]|10)|braces)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
20) optimized should compile: {{1..10},braces}:
AssertionError: {{1..10},braces}
"['(([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']" !== "['(([1-9]|10)|braces)']"
+ expected - actual
-['(([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']
+['(([1-9]|10)|braces)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
21) optimized should compile: x{{0..10},braces}y:
AssertionError: x{{0..10},braces}y
"['x((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)y']" !== "['x(([0-9]|10)|braces)y']"
+ expected - actual
-['x((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)y']
+['x(([0-9]|10)|braces)y']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
22) optimized should compile: {1..10}:
AssertionError: {1..10}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9]|10)']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
23) optimized should compile: {braces,{0..10}}:
AssertionError: {braces,{0..10}}
"['(braces|(function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }))']" !== "['(braces|([0-9]|10))']"
+ expected - actual
-['(braces|(function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }))']
+['(braces|([0-9]|10))']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
24) optimized should compile: {{0..10},braces}:
AssertionError: {{0..10},braces}
"['((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']" !== "['(([0-9]|10)|braces)']"
+ expected - actual
-['((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']
+['(([0-9]|10)|braces)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
25) optimized should compile: {{1..10},braces}:
AssertionError: {{1..10},braces}
"['(([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']" !== "['(([1-9]|10)|braces)']"
+ expected - actual
-['(([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)']
+['(([1-9]|10)|braces)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
26) optimized should compile: 0{1..9} {10..20}:
AssertionError: 0{1..9} {10..20}
"['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }) (1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['0([1-9]) (1[0-9]|20)']"
+ expected - actual
-['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }) (1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['0([1-9]) (1[0-9]|20)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
27) optimized should compile: a{0..3}d:
AssertionError: a{0..3}d
"['a([0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })d']" !== "['a([0-3])d']"
+ expected - actual
-['a([0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })d']
+['a([0-3])d']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
28) optimized should compile: x{10..1}y:
AssertionError: x{10..1}y
"['x([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })y']" !== "['x([1-9]|10)y']"
+ expected - actual
-['x([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })y']
+['x([1-9]|10)y']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
29) optimized should compile: {1..10}:
AssertionError: {1..10}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9]|10)']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
30) optimized should compile: {1..3}:
AssertionError: {1..3}
"['([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-3])']"
+ expected - actual
-['([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-3])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
31) optimized should compile: {1..9}:
AssertionError: {1..9}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9])']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
32) optimized should compile: {10..1}:
AssertionError: {10..1}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9]|10)']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
33) optimized should compile: {10..1}y:
AssertionError: {10..1}y
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })y']" !== "['([1-9]|10)y']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })y']
+['([1-9]|10)y']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
34) optimized should compile: {5..8}:
AssertionError: {5..8}
"['([5-8]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([5-8])']"
+ expected - actual
-['([5-8]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([5-8])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
35) optimized should compile: {-10..-1}:
AssertionError: {-10..-1}
"['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(-[1-9]|-10)']"
+ expected - actual
-['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(-[1-9]|-10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
36) optimized should compile: {-20..0}:
AssertionError: {-20..0}
"['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|-20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|0function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(-[1-9]|-1[0-9]|-20|0)']"
+ expected - actual
-['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|-20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|0function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(-[1-9]|-1[0-9]|-20|0)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
37) optimized should compile: {0..-5}:
AssertionError: {0..-5}
"['(-[1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|0function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(-[1-5]|0)']"
+ expected - actual
-['(-[1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|0function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(-[1-5]|0)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
38) optimized should compile: {9..-4}:
AssertionError: {9..-4}
"['(-[1-4]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']" !== "['(-[1-4]|[0-9])']"
+ expected - actual
-['(-[1-4]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']
+['(-[1-4]|[0-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
39) optimized should compile: 0{1..9}/{10..20}:
AssertionError: 0{1..9}/{10..20}
"['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/(1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['0([1-9])/(1[0-9]|20)']"
+ expected - actual
-['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/(1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['0([1-9])/(1[0-9]|20)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
40) optimized should compile: {-10..10}:
AssertionError: {-10..10}
"['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-?10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']" !== "['(-[1-9]|-?10|[0-9])']"
+ expected - actual
-['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-?10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']
+['(-[1-9]|-?10|[0-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
41) optimized should compile: {2147483645..2147483649}:
AssertionError: {2147483645..2147483649}
"['(214748364[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(214748364[5-9])']"
+ expected - actual
-['(214748364[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(214748364[5-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
42) optimized should compile: {214748364..2147483649}:
AssertionError: {214748364..2147483649}
"['(21474836[4-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|2147483[7-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|214748[4-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{2}|214749function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{3}|2147[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{4}|214[8-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{5}|21[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{6}|2[2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{7}|[3-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{8}|1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{9}|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{8}|21[0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{7}|214[0-6]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{6}|2147[0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{5}|21474[0-7]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{4}|214748[0-2]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{3}|2147483[0-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{2}|21474836[0-4]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']" !== "['(21474836[4-9]|2147483[7-9][0-9]|214748[4-9][0-9]{2}|214749[0-9]{3}|2147[5-9][0-9]{4}|214[8-9][0-9]{5}|21[5-9][0-9]{6}|2[2-9][0-9]{7}|[3-9][0-9]{8}|1[0-9]{9}|20[0-9]{8}|21[0-3][0-9]{7}|214[0-6][0-9]{6}|2147[0-3][0-9]{5}|21474[0-7][0-9]{4}|214748[0-2][0-9]{3}|2147483[0-5][0-9]{2}|21474836[0-4][0-9])']"
+ expected - actual
-['(21474836[4-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|2147483[7-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|214748[4-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{2}|214749function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{3}|2147[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{4}|214[8-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{5}|21[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{6}|2[2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{7}|[3-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{8}|1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{9}|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{8}|21[0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{7}|214[0-6]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{6}|2147[0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{5}|21474[0-7]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{4}|214748[0-2]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{3}|2147483[0-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]{2}|21474836[0-4]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']
+['(21474836[4-9]|2147483[7-9][0-9]|214748[4-9][0-9]{2}|214749[0-9]{3}|2147[5-9][0-9]{4}|214[8-9][0-9]{5}|21[5-9][0-9]{6}|2[2-9][0-9]{7}|[3-9][0-9]{8}|1[0-9]{9}|20[0-9]{8}|21[0-3][0-9]{7}|214[0-6][0-9]{6}|2147[0-3][0-9]{5}|21474[0-7][0-9]{4}|214748[0-2][0-9]{3}|2147483[0-5][0-9]{2}|21474836[0-4][0-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
43) optimized should compile: {1..10..1}:
AssertionError: {1..10..1}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9]|10)']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
44) optimized should compile: {2..10..1}:
AssertionError: {2..10..1}
"['([2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([2-9]|10)']"
+ expected - actual
-['([2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([2-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
45) optimized should compile: {-2..-10..1}:
AssertionError: {-2..-10..1}
"['(-[2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(-[2-9]|-10)']"
+ expected - actual
-['(-[2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(-[2-9]|-10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
46) optimized should compile: ../{1..3}/../foo:
AssertionError: ../{1..3}/../foo
"['../([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/../foo']" !== "['../([1-3])/../foo']"
+ expected - actual
-['../([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/../foo']
+['../([1-3])/../foo']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
47) optimized should compile: ../{1..3}/../{a,b,c}/foo:
AssertionError: ../{1..3}/../{a,b,c}/foo
"['../([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/../(a|b|c)/foo']" !== "['../([1-3])/../(a|b|c)/foo']"
+ expected - actual
-['../([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/../(a|b|c)/foo']
+['../([1-3])/../(a|b|c)/foo']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
48) optimized should compile: a/{x,y}/{1..5}c{d,e}f.{md,txt}:
AssertionError: a/{x,y}/{1..5}c{d,e}f.{md,txt}
"['a/(x|y)/([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })c(d|e)f.(md|txt)']" !== "['a/(x|y)/([1-5])c(d|e)f.(md|txt)']"
+ expected - actual
-['a/(x|y)/([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })c(d|e)f.(md|txt)']
+['a/(x|y)/([1-5])c(d|e)f.(md|txt)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
49) optimized should compile: a/{x,{1..5},y}/c{d}e:
AssertionError: a/{x,{1..5},y}/c{d}e
"['a/(x|([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|y)/c{d}e']" !== "['a/(x|([1-5])|y)/c{d}e']"
+ expected - actual
-['a/(x|([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|y)/c{d}e']
+['a/(x|([1-5])|y)/c{d}e']
at test/support/compare.js:31:12
at Context.<anonymous> (test/bash.optimized.js:402:7)
50) optimized ranges large numbers should expand large numbers:
AssertionError: {2147483645..2147483649}
"['(214748364[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(214748364[5-9])']"
+ expected - actual
-['(214748364[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(214748364[5-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/expanded.js:298:9)
51) optimized sets set expansion should support sequence brace operators:
AssertionError: x{{0..10},braces}y
"['x((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)y']" !== "['x(([0-9]|10)|braces)y']"
+ expected - actual
-['x((function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|braces)y']
+['x(([0-9]|10)|braces)y']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:95:9)
52) optimized sets spaces should handle spaces:
AssertionError: 0{1..9} {10..20}
"['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }) (1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['0([1-9]) (1[0-9]|20)']"
+ expected - actual
-['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }) (1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['0([1-9]) (1[0-9]|20)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:139:9)
53) optimized ranges positive numeric ranges should expand numeric ranges:
AssertionError: a{0..3}d
"['a([0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })d']" !== "['a([0-3])d']"
+ expected - actual
-['a([0-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })d']
+['a([0-3])d']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:213:9)
54) optimized ranges negative ranges should expand ranges with negative numbers:
AssertionError: {-1..-10}
"['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(-[1-9]|-10)']"
+ expected - actual
-['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(-[1-9]|-10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:228:9)
55) optimized ranges alphabetical ranges should expand alphabetical ranges:
AssertionError: 0{1..9}/{10..20}
"['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/(1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['0([1-9])/(1[0-9]|20)']"
+ expected - actual
-['0([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/(1function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9]|20function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['0([1-9])/(1[0-9]|20)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:238:9)
56) optimized ranges combo should expand numerical ranges - positive and negative:
AssertionError: {-10..10}
"['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-?10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']" !== "['(-[1-9]|-?10|[0-9])']"
+ expected - actual
-['(-[1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-?10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }[0-9])']
+['(-[1-9]|-?10|[0-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:261:9)
57) optimized ranges large numbers should expand large numbers:
AssertionError: {2147483645..2147483649}
"['(214748364[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(214748364[5-9])']"
+ expected - actual
-['(214748364[5-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(214748364[5-9])']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:268:9)
58) optimized ranges steps > positive ranges should expand ranges using steps::
AssertionError: {1..10..1}
"['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['([1-9]|10)']"
+ expected - actual
-['([1-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['([1-9]|10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:275:9)
59) optimized ranges steps > negative ranges should expand negative ranges using steps::
AssertionError: {-2..-10..1}
"['(-[2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']" !== "['(-[2-9]|-10)']"
+ expected - actual
-['(-[2-9]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }|-10function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })']
+['(-[2-9]|-10)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:300:9)
60) optimized integration should work with dots in file paths:
AssertionError: ../{1..3}/../foo
"['../([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/../foo']" !== "['../([1-3])/../foo']"
+ expected - actual
-['../([1-3]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })/../foo']
+['../([1-3])/../foo']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:335:7)
61) optimized integration should expand a complex combination of ranges and sets::
AssertionError: a/{x,y}/{1..5}c{d,e}f.{md,txt}
"['a/(x|y)/([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })c(d|e)f.(md|txt)']" !== "['a/(x|y)/([1-5])c(d|e)f.(md|txt)']"
+ expected - actual
-['a/(x|y)/([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })c(d|e)f.(md|txt)']
+['a/(x|y)/([1-5])c(d|e)f.(md|txt)']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:343:7)
62) optimized integration should expand complex sets and ranges in `bash` mode::
AssertionError: a/{x,{1..5},y}/c{d}e
"['a/(x|([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|y)/c{d}e']" !== "['a/(x|([1-5])|y)/c{d}e']"
+ expected - actual
-['a/(x|([1-5]function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n }function () {n var retValue = null;nn state.currentCmd = cmd;n state.error = null;nn try {n var args = [].slice.call(arguments, 0);nn if (config.verbose) {n args.unshift(cmd);n console.log.apply(console, args);n args.shift();n }nn if (options && options.notUnix) {n retValue = fn.apply(this, args);n } else {n if (typeof args[0] === 'object' && args[0].constructor.name === 'Object') {n args = args; // object count as optionsn } else if (args.length === 0 || typeof args[0] !== 'string' || args[0].length <= 1 || args[0][0] !== '-') {n args.unshift(''); // only add dummy option if '-option' not already presentn }n // Expand the '~' if appropriaten var homeDir = getUserHome();n args = args.map(function(arg) {n if (typeof arg === 'string' && arg.slice(0, 2) === '~/' || arg === '~')n return arg.replace(/^~/, homeDir);n elsen return arg;n });n retValue = fn.apply(this, args);n }n } catch (e) {n if (!state.error) {n // If state.error hasn't been set it's an error thrown by Node, not us - probably a bug...n console.log('shell.js: internal error');n console.log(e.stack || e);n process.exit(1);n }n if (config.fatal)n throw e;n }nn state.currentCmd = 'shell.js';n return retValue;n })|y)/c{d}e']
+['a/(x|([1-5])|y)/c{d}e']
at test/support/compare.js:31:12
at Context.<anonymous> (test/optimized.js:347:7)
[07:21:45] 'test' errored after 8.15 s
[07:21:45] Error in plugin 'gulp-mocha'
Message:
62 tests failed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment