Compare commits
3986 Commits
0.3.2
...
2.0.0-beta
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
db216ec384 | ||
|
|
9b77371ea8 | ||
|
|
72cf485dce | ||
|
|
d20f54967e | ||
|
|
fb60070647 | ||
|
|
be7c1be75f | ||
|
|
8292d25d29 | ||
|
|
76945ab458 | ||
|
|
90ec761f95 | ||
|
|
050aaa40f8 | ||
|
|
0576eb3a10 | ||
|
|
7129f8347e | ||
|
|
4d25907155 | ||
|
|
b192e215a5 | ||
|
|
5e1d978946 | ||
|
|
a7447d5bba | ||
|
|
2d1addf5a4 | ||
|
|
962374aec1 | ||
|
|
ed4c8286a2 | ||
|
|
fcf7ddaf45 | ||
|
|
725fe8e018 | ||
|
|
5596dac5e1 | ||
|
|
57c0b16eeb | ||
|
|
0c06fb2b9f | ||
|
|
cfdec64958 | ||
|
|
d0c6e53b83 | ||
|
|
27caf62322 | ||
|
|
b8df321058 | ||
|
|
c1e3c02d13 | ||
|
|
06f6efa6d5 | ||
|
|
c035d53fb0 | ||
|
|
dde7b0d98a | ||
|
|
98d1644c5b | ||
|
|
5888ac56d8 | ||
|
|
a6bf72a791 | ||
|
|
3aa177c88f | ||
|
|
608799f5d0 | ||
|
|
97aef9b30d | ||
|
|
ca0fd229e1 | ||
|
|
a9bd53d77f | ||
|
|
ccbf3152af | ||
|
|
f8ce1a8183 | ||
|
|
cee1076e1d | ||
|
|
f8c150f201 | ||
|
|
a5cb8cd7c3 | ||
|
|
32799ad732 | ||
|
|
d47f90599e | ||
|
|
5817aeb837 | ||
|
|
7de06c3dcb | ||
|
|
6f0f173795 | ||
|
|
221a8720fe | ||
|
|
ff56533e0b | ||
|
|
e88619a3bb | ||
|
|
91e3f7255c | ||
|
|
664c7a4743 | ||
|
|
f018e94be9 | ||
|
|
79d38cc30b | ||
|
|
ee8f022317 | ||
|
|
98c1a3a045 | ||
|
|
d84c94dc6d | ||
|
|
4f714cc7f9 | ||
|
|
fbc77f7445 | ||
|
|
f757614334 | ||
|
|
94023d88ca | ||
|
|
4547cbac3a | ||
|
|
856bf5e68c | ||
|
|
f4a1172b6f | ||
|
|
9866224dba | ||
|
|
8a271995c7 | ||
|
|
c06a0584ff | ||
|
|
37e6513c02 | ||
|
|
4cc701a9da | ||
|
|
d2e94c6ebd | ||
|
|
d7d32cf0b6 | ||
|
|
ebe32d35e2 | ||
|
|
ecafe7ce0f | ||
|
|
41a229e22e | ||
|
|
d9194b2670 | ||
|
|
365d1968e9 | ||
|
|
eebc432efb | ||
|
|
dd5aa2b7a4 | ||
|
|
d1d2c16fdd | ||
|
|
ef1898ba42 | ||
|
|
3d0d04efe2 | ||
|
|
81cbca5bb8 | ||
|
|
da3db1be39 | ||
|
|
396bd4f2f2 | ||
|
|
cbea7b5d1c | ||
|
|
87e537c917 | ||
|
|
b61324058d | ||
|
|
3e7973e08d | ||
|
|
635e207f3f | ||
|
|
e87d5749bd | ||
|
|
ec5adf53a7 | ||
|
|
48eb173bcd | ||
|
|
b89dd043d3 | ||
|
|
8ce7c30c49 | ||
|
|
45d0a7d01f | ||
|
|
729127735b | ||
|
|
6d27277ef6 | ||
|
|
3108244c20 | ||
|
|
69a07dfa6d | ||
|
|
800116d859 | ||
|
|
4f6073f283 | ||
|
|
d0ed2dee60 | ||
|
|
a61429c947 | ||
|
|
fbdfa65734 | ||
|
|
02198eb967 | ||
|
|
cd8be896c4 | ||
|
|
b398c8809a | ||
|
|
9e13100f58 | ||
|
|
52bc1dab0b | ||
|
|
ff9f078a89 | ||
|
|
8d81804fee | ||
|
|
f4353fa797 | ||
|
|
e6f5b930bc | ||
|
|
87e70ee78b | ||
|
|
fc1d4edbfd | ||
|
|
5f00ccc362 | ||
|
|
1143ac0268 | ||
|
|
0fc625d7e9 | ||
|
|
ef1005b920 | ||
|
|
5cf8256d2e | ||
|
|
0a6aeef0c9 | ||
|
|
ebb56e08ca | ||
|
|
27e0914a0d | ||
|
|
f0e884dc4e | ||
|
|
24bef3a1f5 | ||
|
|
5d557a54e1 | ||
|
|
3379f233e8 | ||
|
|
26b1584fd8 | ||
|
|
5fa91e7b95 | ||
|
|
d8bd2b7fd0 | ||
|
|
d02376c4c6 | ||
|
|
69fbb361f2 | ||
|
|
4468ca69c0 | ||
|
|
a4b3a3ba39 | ||
|
|
ad90f4ad99 | ||
|
|
cc8dd150f5 | ||
|
|
7ced071934 | ||
|
|
28d077c08a | ||
|
|
31ff5e4194 | ||
|
|
ea269104bd | ||
|
|
78b21c2483 | ||
|
|
fc42b3ed24 | ||
|
|
c8a3c1a6fd | ||
|
|
58f9428c58 | ||
|
|
3c6e235b32 | ||
|
|
35cfba06b4 | ||
|
|
f01dcd3894 | ||
|
|
de180dc81a | ||
|
|
e48fea1892 | ||
|
|
47bd5aca58 | ||
|
|
0aa3166709 | ||
|
|
51aaef3d76 | ||
|
|
d62f7adc9b | ||
|
|
853dd456a8 | ||
|
|
462a60da7b | ||
|
|
4abd0fa06d | ||
|
|
e2a3a5b993 | ||
|
|
8c81c4ad39 | ||
|
|
b1313962a7 | ||
|
|
e620434a2e | ||
|
|
2a862d533f | ||
|
|
be0f1cb8db | ||
|
|
07d6eb6af5 | ||
|
|
a825336ba9 | ||
|
|
81174187f5 | ||
|
|
a55dbc0c37 | ||
|
|
818d262843 | ||
|
|
e05a4e9000 | ||
|
|
c3b3af8746 | ||
|
|
4889109b8d | ||
|
|
93f1f3777c | ||
|
|
14382abc2d | ||
|
|
aee27fbff0 | ||
|
|
28585439d1 | ||
|
|
85b3be9ce3 | ||
|
|
512b580820 | ||
|
|
e90cf16965 | ||
|
|
59001f2fe3 | ||
|
|
db055bb916 | ||
|
|
80fdc6ecc3 | ||
|
|
ff1725b367 | ||
|
|
d278c730ea | ||
|
|
4aa0130a92 | ||
|
|
c7ad70731a | ||
|
|
16dda9c496 | ||
|
|
b2e10e597f | ||
|
|
b2bf505e4c | ||
|
|
9c9058ebb4 | ||
|
|
ece610d682 | ||
|
|
d61d4272ce | ||
|
|
618e851cd6 | ||
|
|
2167a7ab2e | ||
|
|
ec9e559ec0 | ||
|
|
07e4047b7f | ||
|
|
7bb5ccfd80 | ||
|
|
eb36d6e7a2 | ||
|
|
000dc03360 | ||
|
|
0dd727e6eb | ||
|
|
6a845aa4f6 | ||
|
|
9eb7c63158 | ||
|
|
0f10082a21 | ||
|
|
6bd087ebb2 | ||
|
|
7704cf571e | ||
|
|
26cfd19862 | ||
|
|
6a678f23a5 | ||
|
|
c7539e3310 | ||
|
|
e139d59896 | ||
|
|
b481bd1f73 | ||
|
|
04961afa36 | ||
|
|
6fc9e338a5 | ||
|
|
df5dd7e383 | ||
|
|
8fbe095e94 | ||
|
|
2392a91033 | ||
|
|
0145bf397a | ||
|
|
d524dc8ad0 | ||
|
|
d2fb1b5ce8 | ||
|
|
a80d74a672 | ||
|
|
286eec74f9 | ||
|
|
88f2bf9fa5 | ||
|
|
3ea0481bbe | ||
|
|
03eceeb615 | ||
|
|
81b9fe34ff | ||
|
|
fb3e1a8e65 | ||
|
|
fb0639fa38 | ||
|
|
b7dbee2402 | ||
|
|
2ca0f44cc8 | ||
|
|
c5121c8c4e | ||
|
|
2f72d0394f | ||
|
|
026d9d6ccd | ||
|
|
c9de5be966 | ||
|
|
d45d780869 | ||
|
|
d8abfae457 | ||
|
|
98bf335777 | ||
|
|
1a69493f87 | ||
|
|
abe746bf53 | ||
|
|
075e48df95 | ||
|
|
47c0a5cbef | ||
|
|
c48f5ce30f | ||
|
|
4efd27ed28 | ||
|
|
e6b1218ae1 | ||
|
|
68938cda30 | ||
|
|
7d6a3b5fa4 | ||
|
|
f187440bb8 | ||
|
|
d0d2ef9f77 | ||
|
|
a15bf3d336 | ||
|
|
6d507b46d3 | ||
|
|
ba3411a1ac | ||
|
|
5588658641 | ||
|
|
d99ae0e7ef | ||
|
|
cf3a27259a | ||
|
|
1ea753d19f | ||
|
|
831d3c9341 | ||
|
|
729fec2947 | ||
|
|
faab9330e9 | ||
|
|
8c8ebf874a | ||
|
|
06b3180223 | ||
|
|
6d29086519 | ||
|
|
a401f587c3 | ||
|
|
6685771255 | ||
|
|
ac26360fdc | ||
|
|
e38866b2bf | ||
|
|
6f6df0e48d | ||
|
|
33e6242f6f | ||
|
|
ac20f6634a | ||
|
|
5c765f4cc7 | ||
|
|
aff191fc53 | ||
|
|
02c5641b32 | ||
|
|
dd0a4f33ee | ||
|
|
4d4839011b | ||
|
|
0ef9eef87d | ||
|
|
555e47dbb9 | ||
|
|
14a63149f4 | ||
|
|
992eb49e92 | ||
|
|
8ea67ff3e9 | ||
|
|
ceca091816 | ||
|
|
56482a3166 | ||
|
|
6c759d49bd | ||
|
|
bc471da960 | ||
|
|
6f595f8fd3 | ||
|
|
cc3be717a0 | ||
|
|
42a10ba39e | ||
|
|
a21ce38fdf | ||
|
|
073e14746e | ||
|
|
f8fa52a5d7 | ||
|
|
78e1f43b24 | ||
|
|
57ffe14fab | ||
|
|
a49c5c5150 | ||
|
|
24033eb11a | ||
|
|
f32740c032 | ||
|
|
bebc5812e5 | ||
|
|
4ab6fbca72 | ||
|
|
7bc5b73db1 | ||
|
|
a95d986055 | ||
|
|
846c0e4c51 | ||
|
|
3736b0fed1 | ||
|
|
eb46975d87 | ||
|
|
3739954de6 | ||
|
|
3b0b002f29 | ||
|
|
6f09d36ec8 | ||
|
|
9524159e68 | ||
|
|
b3896d08e8 | ||
|
|
dc25f462a9 | ||
|
|
663595ba94 | ||
|
|
8b1c109b9c | ||
|
|
ea3f044816 | ||
|
|
993f459880 | ||
|
|
43e580321a | ||
|
|
327395d793 | ||
|
|
acb3c8d79c | ||
|
|
ad4a6c4877 | ||
|
|
496fd5d3d3 | ||
|
|
aca72f9b91 | ||
|
|
c5afb4e2fd | ||
|
|
a1bcf7f1d9 | ||
|
|
0d132318ce | ||
|
|
9e0a4f844a | ||
|
|
26ad6d4670 | ||
|
|
fb2be8e1e3 | ||
|
|
c04c3850ec | ||
|
|
887052de07 | ||
|
|
f14e8b279c | ||
|
|
70a7265f35 | ||
|
|
6087c2c8fc | ||
|
|
0521c3582c | ||
|
|
b35bb20a18 | ||
|
|
def685a4e1 | ||
|
|
8647e50941 | ||
|
|
8b50fd0461 | ||
|
|
01890cd415 | ||
|
|
3c42b400a1 | ||
|
|
be44ebd2cd | ||
|
|
a1809277a0 | ||
|
|
4d3d7352f1 | ||
|
|
48e00d81a9 | ||
|
|
0853b412c6 | ||
|
|
a75fe280f2 | ||
|
|
e14946b3e6 | ||
|
|
88693e420d | ||
|
|
ce971b766f | ||
|
|
11561dddcf | ||
|
|
7c7bc8ee2f | ||
|
|
7b9fbf2c76 | ||
|
|
8623792bcd | ||
|
|
809634ba39 | ||
|
|
8138c663a8 | ||
|
|
46841d916d | ||
|
|
c5c4d7c8f8 | ||
|
|
f8b0c8049c | ||
|
|
1d230fe055 | ||
|
|
0b2d852f67 | ||
|
|
964a588e29 | ||
|
|
329b2d1cb2 | ||
|
|
568a0c7b4e | ||
|
|
57f5297714 | ||
|
|
32041806ae | ||
|
|
b0d8fca245 | ||
|
|
c3f5b8db86 | ||
|
|
2923e88207 | ||
|
|
66b5203689 | ||
|
|
e908fd4a91 | ||
|
|
ab97e2224e | ||
|
|
f6bc4b4c32 | ||
|
|
bb40b1188c | ||
|
|
98068611b1 | ||
|
|
a8b77fb4e7 | ||
|
|
7667cb2370 | ||
|
|
51f24e0641 | ||
|
|
9ae377b481 | ||
|
|
0e0e8f87e1 | ||
|
|
ec9c4d8594 | ||
|
|
66ac8af678 | ||
|
|
feb42e5128 | ||
|
|
bd0024a9c2 | ||
|
|
133fadd36a | ||
|
|
a5980247dc | ||
|
|
ec333a061b | ||
|
|
0247b135f8 | ||
|
|
d7e752bc5d | ||
|
|
7c2f348a63 | ||
|
|
88192c197a | ||
|
|
d7385ece46 | ||
|
|
e318469cb0 | ||
|
|
6291b53492 | ||
|
|
841b3cd2ad | ||
|
|
9a0babf5b1 | ||
|
|
cbc72a29bf | ||
|
|
e42fc47747 | ||
|
|
5b7ac32905 | ||
|
|
4d8cd03298 | ||
|
|
585932cf5b | ||
|
|
8afb7cc95b | ||
|
|
021d2e4376 | ||
|
|
87216ea5b6 | ||
|
|
f80a8a5120 | ||
|
|
9590ad7622 | ||
|
|
402133a50e | ||
|
|
34b4311544 | ||
|
|
65c35e05a1 | ||
|
|
f7277c9de5 | ||
|
|
08129d0f1f | ||
|
|
347a625525 | ||
|
|
2df011f378 | ||
|
|
97882b8e49 | ||
|
|
67b0f95d4d | ||
|
|
ce84924101 | ||
|
|
ae72dbb379 | ||
|
|
b8403bfa97 | ||
|
|
f179b20e6e | ||
|
|
0995ba361c | ||
|
|
89921c0667 | ||
|
|
87a854afb4 | ||
|
|
1dd5795960 | ||
|
|
968f94f782 | ||
|
|
4b4675de30 | ||
|
|
36e80d7f5c | ||
|
|
2536bfd75c | ||
|
|
4acafad07b | ||
|
|
73b05a55b6 | ||
|
|
de2db48474 | ||
|
|
4ceb6a6818 | ||
|
|
d6ff91a454 | ||
|
|
da23a2f702 | ||
|
|
d1c6db476b | ||
|
|
b1ef5a9996 | ||
|
|
c1a9cfa044 | ||
|
|
d3cff9082f | ||
|
|
1739c9d720 | ||
|
|
75a4c01e17 | ||
|
|
8711da03a2 | ||
|
|
eb6baf2d9b | ||
|
|
d742a7dd1f | ||
|
|
ae65875c8b | ||
|
|
fcf5924dae | ||
|
|
f26d33d418 | ||
|
|
cea773ec81 | ||
|
|
6c6c8d48bf | ||
|
|
98dd1bf8e8 | ||
|
|
56d75baac7 | ||
|
|
0872c3d13d | ||
|
|
5095e02b62 | ||
|
|
874628b1d0 | ||
|
|
ff9d5117f9 | ||
|
|
10aca2a38e | ||
|
|
2c4d437e98 | ||
|
|
c0c13c1977 | ||
|
|
6d9553a016 | ||
|
|
66716cd730 | ||
|
|
f588ecb288 | ||
|
|
dc3e177811 | ||
|
|
2eef667916 | ||
|
|
617a932e89 | ||
|
|
beac56d4d5 | ||
|
|
cc98e99070 | ||
|
|
93e4eeafed | ||
|
|
efdc67241a | ||
|
|
24e8f1c98f | ||
|
|
2d1a6fa6ec | ||
|
|
3d7d68a766 | ||
|
|
342b395b0a | ||
|
|
75ae45e2bb | ||
|
|
1f197fcc1b | ||
|
|
e339f5f2da | ||
|
|
c37f284771 | ||
|
|
585298dc17 | ||
|
|
2087923163 | ||
|
|
b58772e8a7 | ||
|
|
769f02ec05 | ||
|
|
52b1749d57 | ||
|
|
ba85a38cb0 | ||
|
|
c0d44b1abd | ||
|
|
0262322400 | ||
|
|
8e8f6d13bd | ||
|
|
b6667f0735 | ||
|
|
99ea1c7a39 | ||
|
|
27fd65390a | ||
|
|
79a6d89849 | ||
|
|
6fb5833843 | ||
|
|
5494ac13ee | ||
|
|
300faf401c | ||
|
|
f2c6066103 | ||
|
|
2a5320fd2b | ||
|
|
36695540fc | ||
|
|
fc0c4fdd5f | ||
|
|
ebc172d1ee | ||
|
|
4e6b6678f7 | ||
|
|
378a04e48c | ||
|
|
1e62781759 | ||
|
|
234adef20c | ||
|
|
8b463cd3ad | ||
|
|
ce10a463f3 | ||
|
|
140a73dca7 | ||
|
|
46d16b5c49 | ||
|
|
d16cf19c15 | ||
|
|
edbb9a77e7 | ||
|
|
cc4c3b2606 | ||
|
|
3a2888f97a | ||
|
|
bd17cc9b3c | ||
|
|
0a3e3639dc | ||
|
|
008bacf5d5 | ||
|
|
cc1b056b03 | ||
|
|
3548b4883e | ||
|
|
37a376497c | ||
|
|
83744917b0 | ||
|
|
a548b70e8c | ||
|
|
c8147c046a | ||
|
|
4a7497b451 | ||
|
|
06aa329596 | ||
|
|
9becb0e937 | ||
|
|
7f7765546f | ||
|
|
c7a365b6f1 | ||
|
|
84c125a71b | ||
|
|
06b74591e7 | ||
|
|
6645fbb895 | ||
|
|
c2758da9eb | ||
|
|
7a1c8fef0a | ||
|
|
71c59dddcc | ||
|
|
ef6f90753a | ||
|
|
50fff63252 | ||
|
|
8f5c77c3ce | ||
|
|
88529bc339 | ||
|
|
f37f9d1eda | ||
|
|
836175baab | ||
|
|
7395ac1d4f | ||
|
|
61988fe361 | ||
|
|
533ad8afe9 | ||
|
|
1961f06e08 | ||
|
|
4503e2716e | ||
|
|
e4d81005be | ||
|
|
b6012c4617 | ||
|
|
feee6954a6 | ||
|
|
fea058c53a | ||
|
|
25d97aa136 | ||
|
|
7c8849cc21 | ||
|
|
b362bd672c | ||
|
|
a4f510501c | ||
|
|
e3f6e19950 | ||
|
|
b49b41320e | ||
|
|
6bc3157793 | ||
|
|
dc8a2b17d0 | ||
|
|
c3ae2328af | ||
|
|
57846ea5c0 | ||
|
|
3da88b9b3f | ||
|
|
8130e63e43 | ||
|
|
dc44ebbdaa | ||
|
|
88ad059d54 | ||
|
|
76c076db55 | ||
|
|
5698e6c72a | ||
|
|
e0e4967ad8 | ||
|
|
53c7891599 | ||
|
|
94a17cb74a | ||
|
|
5d139596f8 | ||
|
|
213225418a | ||
|
|
3b3e52097a | ||
|
|
72ceec5680 | ||
|
|
5a220d4e13 | ||
|
|
92e5ab2857 | ||
|
|
64632e3332 | ||
|
|
c0e1f23f23 | ||
|
|
ee8f889cbd | ||
|
|
ffa25aae77 | ||
|
|
04b30a6cc4 | ||
|
|
996a171a4e | ||
|
|
17a271af06 | ||
|
|
f8c366c479 | ||
|
|
934bd2acc7 | ||
|
|
dd0ec84ebe | ||
|
|
e9a372dff5 | ||
|
|
4d7a0d2470 | ||
|
|
c2abe253a1 | ||
|
|
3ddd3115eb | ||
|
|
a3096eab91 | ||
|
|
3fd004b852 | ||
|
|
0a9c7a3257 | ||
|
|
f7692c92ce | ||
|
|
cdf69eb5bc | ||
|
|
9aeecf582b | ||
|
|
e0ec8a51e4 | ||
|
|
a62e49311e | ||
|
|
9a38486d08 | ||
|
|
06e8be5d94 | ||
|
|
90a1cbac49 | ||
|
|
3d58b4cda1 | ||
|
|
2f0724f0ad | ||
|
|
f288d20409 | ||
|
|
dca915af60 | ||
|
|
54a4560340 | ||
|
|
518d7c16b7 | ||
|
|
8ed691e266 | ||
|
|
74fc7128ab | ||
|
|
68c0e2dc0f | ||
|
|
42dde38842 | ||
|
|
7d6f6174d5 | ||
|
|
05b3707506 | ||
|
|
5d1d1b7999 | ||
|
|
3db029f2c1 | ||
|
|
67aaa8b57f | ||
|
|
28c07d30cb | ||
|
|
fce502ac98 | ||
|
|
669e7fed10 | ||
|
|
4bf45ff894 | ||
|
|
4c2c472e07 | ||
|
|
22f19522ff | ||
|
|
9fa77af576 | ||
|
|
efd7ebb066 | ||
|
|
62712060c0 | ||
|
|
a46978640b | ||
|
|
8ab15d7372 | ||
|
|
23a691ae87 | ||
|
|
bec8f27e8a | ||
|
|
ac2e540e1b | ||
|
|
e0ad0d795d | ||
|
|
a63009fccb | ||
|
|
8fd6258a46 | ||
|
|
24398774fc | ||
|
|
e769423d52 | ||
|
|
9ec427ba80 | ||
|
|
c478f283f4 | ||
|
|
8e299b09cc | ||
|
|
b70f6571bd | ||
|
|
ae6df88c5c | ||
|
|
0dcff507fb | ||
|
|
8e4fb1b937 | ||
|
|
931b74e449 | ||
|
|
4199f4f325 | ||
|
|
5950d6328d | ||
|
|
a9fbf14adf | ||
|
|
485aa8efcf | ||
|
|
a563e8f8fe | ||
|
|
4035e7caab | ||
|
|
2c6e6ca870 | ||
|
|
f2a3f7507e | ||
|
|
4f82e5912e | ||
|
|
dd5da7f5f2 | ||
|
|
ec44aba71a | ||
|
|
e8a4e93a72 | ||
|
|
1301390087 | ||
|
|
158ca0d869 | ||
|
|
a78cbe78a1 | ||
|
|
77d5b95260 | ||
|
|
55e3b6b3c3 | ||
|
|
efca2861a6 | ||
|
|
781ea22d57 | ||
|
|
437b9ed65c | ||
|
|
c72556619f | ||
|
|
565d78f00b | ||
|
|
75900660fd | ||
|
|
b407a59baf | ||
|
|
9dfd71b0e4 | ||
|
|
872092f6de | ||
|
|
8b066f125d | ||
|
|
94c467b520 | ||
|
|
53aa50f785 | ||
|
|
81047d45ee | ||
|
|
9177676979 | ||
|
|
7cfba37f7c | ||
|
|
ee8d105194 | ||
|
|
6929441cb7 | ||
|
|
b5734028d9 | ||
|
|
ab6f69c741 | ||
|
|
2ec6e7e944 | ||
|
|
e8c96de269 | ||
|
|
fbbda3f85f | ||
|
|
f96ab11feb | ||
|
|
5c1daf966a | ||
|
|
df8529fbfb | ||
|
|
3465e7554d | ||
|
|
f7b36054fc | ||
|
|
3ec10df4a1 | ||
|
|
deead4bfad | ||
|
|
302aa6a457 | ||
|
|
5920939e23 | ||
|
|
2bab1b6aa1 | ||
|
|
2b539ebea8 | ||
|
|
159d562230 | ||
|
|
eb030a2c73 | ||
|
|
1157b32413 | ||
|
|
ba4157b5e2 | ||
|
|
5a54d8ba6d | ||
|
|
f619416492 | ||
|
|
2dd1ec3314 | ||
|
|
4ad625a265 | ||
|
|
df2b79fa56 | ||
|
|
c4f9c3abf5 | ||
|
|
9410216b02 | ||
|
|
233055a7ab | ||
|
|
edf3c12fcc | ||
|
|
1bb3c843e1 | ||
|
|
48f2c2d0d2 | ||
|
|
7e01672479 | ||
|
|
ddc023b28b | ||
|
|
c65f584112 | ||
|
|
70a9a341ac | ||
|
|
c608901d5a | ||
|
|
a5a1ea9157 | ||
|
|
1cd48a9f5d | ||
|
|
d8b7a55eb9 | ||
|
|
6ae21ae461 | ||
|
|
f0764096e9 | ||
|
|
ade9620351 | ||
|
|
3fdc3a4758 | ||
|
|
03705c674f | ||
|
|
576fe44ef8 | ||
|
|
e02c8abb1a | ||
|
|
2723f1afe9 | ||
|
|
6114751d21 | ||
|
|
15b64addbf | ||
|
|
4547612e50 | ||
|
|
9c15b13a96 | ||
|
|
63acf6a5ff | ||
|
|
3339c2f228 | ||
|
|
c2db81d892 | ||
|
|
8b15d8218d | ||
|
|
bfc9d4d594 | ||
|
|
ab5728c030 | ||
|
|
dcf1556ffc | ||
|
|
53c53bd3e6 | ||
|
|
c2e1ab589c | ||
|
|
75207a08ad | ||
|
|
a2dbfdc2f4 | ||
|
|
0a82ac7d69 | ||
|
|
a489006afb | ||
|
|
af08cfd37f | ||
|
|
9dc3a3df13 | ||
|
|
a82aecc008 | ||
|
|
36a3e03048 | ||
|
|
fc8e9fd92a | ||
|
|
c9e87f3044 | ||
|
|
bb319e2add | ||
|
|
81e2253a55 | ||
|
|
c41a14f447 | ||
|
|
a323160d14 | ||
|
|
a216f93b54 | ||
|
|
551cf56ceb | ||
|
|
09446ad515 | ||
|
|
b31951980e | ||
|
|
e7ba29514d | ||
|
|
a2c0106b3f | ||
|
|
4dfc75dede | ||
|
|
0ad30e9b3f | ||
|
|
46f55d1bb4 | ||
|
|
27f1976159 | ||
|
|
816241d9a1 | ||
|
|
4bbd63c883 | ||
|
|
e9a0512663 | ||
|
|
8980647f32 | ||
|
|
eda4f0c55b | ||
|
|
ed928928f6 | ||
|
|
5f28319cb1 | ||
|
|
6b0ee127da | ||
|
|
5e31672793 | ||
|
|
4ab8503e5a | ||
|
|
cc4cc8e652 | ||
|
|
52b89d5b03 | ||
|
|
094a0cbe95 | ||
|
|
f8eca2e822 | ||
|
|
114eccb459 | ||
|
|
38bd879a9a | ||
|
|
a73a6e24a6 | ||
|
|
b4d35f13a4 | ||
|
|
3fcaebb007 | ||
|
|
3357b6cf2c | ||
|
|
6df8d92499 | ||
|
|
e543eb5101 | ||
|
|
7c4f842501 | ||
|
|
a5fef52751 | ||
|
|
ef7b3a75e0 | ||
|
|
734fcedc06 | ||
|
|
e4c8bcf8f6 | ||
|
|
a3ae0c5c75 | ||
|
|
46895419b3 | ||
|
|
4f6a4bab30 | ||
|
|
9e5ffaea69 | ||
|
|
928d2d7f4a | ||
|
|
10293df1f9 | ||
|
|
41c4c822ba | ||
|
|
6030ac3a23 | ||
|
|
f42329ca0a | ||
|
|
570529f526 | ||
|
|
8b8436d794 | ||
|
|
b0594aad3e | ||
|
|
04b0b94a8c | ||
|
|
e1f46cfb9b | ||
|
|
cc1b74f11b | ||
|
|
104b4666fe | ||
|
|
835fc84330 | ||
|
|
a5d6285cfd | ||
|
|
c2727d964c | ||
|
|
f375394381 | ||
|
|
d687d52f9e | ||
|
|
6a43de789f | ||
|
|
1288786fdc | ||
|
|
2b4421fca1 | ||
|
|
6bdd52733e | ||
|
|
bd6b4142fe | ||
|
|
daa6ad5470 | ||
|
|
369e0545c0 | ||
|
|
5f31a3d60e | ||
|
|
8b976acac1 | ||
|
|
b00962db1a | ||
|
|
26dcf025f4 | ||
|
|
d2f90d2236 | ||
|
|
c3391e1dd8 | ||
|
|
b3463a1378 | ||
|
|
f0463e9981 | ||
|
|
1cc583b382 | ||
|
|
39cb8815f7 | ||
|
|
21db08a23d | ||
|
|
1f301d8c07 | ||
|
|
1e377ed59b | ||
|
|
64e78a2bec | ||
|
|
35f185440f | ||
|
|
5ce0c84907 | ||
|
|
25b1eee293 | ||
|
|
a6891e4feb | ||
|
|
8a3ebb9181 | ||
|
|
dab4ae9416 | ||
|
|
56b04a58dc | ||
|
|
308299fe04 | ||
|
|
1cc8463b9c | ||
|
|
d7862647d9 | ||
|
|
6c786f0fb7 | ||
|
|
cc345def46 | ||
|
|
818983b6a4 | ||
|
|
b859d92d2c | ||
|
|
8cd9ba168d | ||
|
|
08a57898a7 | ||
|
|
ba4743cc83 | ||
|
|
94e22ab819 | ||
|
|
c1b46f777f | ||
|
|
81cf9ca00f | ||
|
|
96f087ca6b | ||
|
|
bc975e556e | ||
|
|
e1000205fd | ||
|
|
c02a403f2e | ||
|
|
6804c1065b | ||
|
|
74cf54a84f | ||
|
|
f4b850d59c | ||
|
|
73af30b5d8 | ||
|
|
54633aee3f | ||
|
|
85c7fffd1a | ||
|
|
9d29a830df | ||
|
|
74a92db173 | ||
|
|
d712a6c0f4 | ||
|
|
7906a2b6c1 | ||
|
|
f11ca9888f | ||
|
|
26200f4640 | ||
|
|
13f205404c | ||
|
|
563f14b178 | ||
|
|
5e4cca90a3 | ||
|
|
a61b6ee925 | ||
|
|
b11d956d53 | ||
|
|
ee9febe399 | ||
|
|
15a70f863c | ||
|
|
4eee9c318e | ||
|
|
ac6a76ee10 | ||
|
|
42aa8d256c | ||
|
|
873ed071d4 | ||
|
|
210376f7a9 | ||
|
|
35d327a304 | ||
|
|
e3e8b1c501 | ||
|
|
52a54a7681 | ||
|
|
1fe28c1fc9 | ||
|
|
89efd05a3f | ||
|
|
caafafcf4d | ||
|
|
81d8224b9a | ||
|
|
22c85e216f | ||
|
|
f047ba52b2 | ||
|
|
130899a39f | ||
|
|
6847400ccb | ||
|
|
1102567b0c | ||
|
|
8c6647849b | ||
|
|
de42ad0e1c | ||
|
|
073d025fac | ||
|
|
efe8c68c75 | ||
|
|
9941050120 | ||
|
|
dafc7bdea5 | ||
|
|
f51cbd7117 | ||
|
|
45d97b3dfe | ||
|
|
fcc88ca472 | ||
|
|
187ebd0374 | ||
|
|
c4999efda7 | ||
|
|
b6231e50c3 | ||
|
|
592aa33577 | ||
|
|
544c99a9ad | ||
|
|
de0e3baf1f | ||
|
|
aea0f2533b | ||
|
|
138c25fe5f | ||
|
|
e0195756dc | ||
|
|
96ae98fade | ||
|
|
efb9809d3b | ||
|
|
0dada3dd27 | ||
|
|
849c8e8ef4 | ||
|
|
9e9c83f788 | ||
|
|
d41d87a874 | ||
|
|
ab40571ffc | ||
|
|
5d13d14de9 | ||
|
|
1df8abf1cb | ||
|
|
45b60c9a52 | ||
|
|
091bc56a96 | ||
|
|
52789f5b19 | ||
|
|
9ba1d41ec8 | ||
|
|
5456bd5f89 | ||
|
|
0d662c3ad2 | ||
|
|
fa76e2dd21 | ||
|
|
08f6c65c3b | ||
|
|
54840c0cbf | ||
|
|
91ac3fa031 | ||
|
|
2853e718f2 | ||
|
|
c22707cd53 | ||
|
|
351c875576 | ||
|
|
35b64d7f18 | ||
|
|
db87d817e8 | ||
|
|
f3c5cc6774 | ||
|
|
4cc2c305a4 | ||
|
|
a5513c45d0 | ||
|
|
c820e0241e | ||
|
|
eb2ac2c64d | ||
|
|
59cf19fd1c | ||
|
|
d5a25d138d | ||
|
|
a7ecd80c92 | ||
|
|
465cffc675 | ||
|
|
302a46d093 | ||
|
|
392767a04e | ||
|
|
928f949761 | ||
|
|
8bb833d858 | ||
|
|
2b03fa9077 | ||
|
|
cfdb774da9 | ||
|
|
b173a377a6 | ||
|
|
581af4540a | ||
|
|
18e5b6b199 | ||
|
|
6da2306fe2 | ||
|
|
a8e4b78803 | ||
|
|
a3be1f6e48 | ||
|
|
89ef3d4117 | ||
|
|
4cf75ec027 | ||
|
|
830c294aea | ||
|
|
bb86e54ece | ||
|
|
359e17277f | ||
|
|
89f5f9d59d | ||
|
|
26c0f7ca2d | ||
|
|
40c1086efa | ||
|
|
999a3db499 | ||
|
|
50e13f62f2 | ||
|
|
fceff1729c | ||
|
|
1765a7ae0c | ||
|
|
ae79ff9fa3 | ||
|
|
3e9d01d6c6 | ||
|
|
ae4535d639 | ||
|
|
c5120c7980 | ||
|
|
92e83489fc | ||
|
|
1b7491d63d | ||
|
|
ce14ad764a | ||
|
|
96e807c677 | ||
|
|
70994d4b50 | ||
|
|
675095efbe | ||
|
|
0235d12927 | ||
|
|
9d24a3420d | ||
|
|
3ad332d5d4 | ||
|
|
15517df417 | ||
|
|
3c2f0d174e | ||
|
|
8cf6f62ea4 | ||
|
|
9e716b310d | ||
|
|
e44bf9ae81 | ||
|
|
f5f99b3022 | ||
|
|
dc3d70e696 | ||
|
|
77fded3c5e | ||
|
|
e644f7244d | ||
|
|
457cdfde26 | ||
|
|
910e38749c | ||
|
|
2b4a37296f | ||
|
|
3f9cdcf1fa | ||
|
|
4342bedd2f | ||
|
|
fdd5796f5e | ||
|
|
f48aa44386 | ||
|
|
51c625205b | ||
|
|
e581f7d2f0 | ||
|
|
3aa646e425 | ||
|
|
92208fec44 | ||
|
|
cdc603c794 | ||
|
|
46d8902004 | ||
|
|
34c1704286 | ||
|
|
19767a0f10 | ||
|
|
0c9f0fd099 | ||
|
|
7f1088054c | ||
|
|
ef5f58e30e | ||
|
|
13024e6911 | ||
|
|
32e8e562ea | ||
|
|
7fdac5c3b9 | ||
|
|
b68fd9d76e | ||
|
|
25c6001a6c | ||
|
|
7250fdd576 | ||
|
|
b7f8443052 | ||
|
|
4fd5e9a3ab | ||
|
|
3785996c44 | ||
|
|
eb0a222eea | ||
|
|
3d761e73e3 | ||
|
|
cc3b4e8080 | ||
|
|
ba7cb3ab69 | ||
|
|
054443c46e | ||
|
|
c8dae22cb0 | ||
|
|
183ec48308 | ||
|
|
13187b0199 | ||
|
|
3c880bf601 | ||
|
|
8e90aaefc1 | ||
|
|
426ae97e49 | ||
|
|
f277a43645 | ||
|
|
2e408648aa | ||
|
|
f2f10e85a8 | ||
|
|
84b8b5ccee | ||
|
|
7b14a6aad2 | ||
|
|
342306587c | ||
|
|
3298c9caad | ||
|
|
7089b02a74 | ||
|
|
bd451800bf | ||
|
|
5e06f7e859 | ||
|
|
0f5ae54014 | ||
|
|
5496a189bc | ||
|
|
2e6a781014 | ||
|
|
b85cf5355f | ||
|
|
f038d0514a | ||
|
|
7c4128ee3b | ||
|
|
012e3c019c | ||
|
|
b3ffd25339 | ||
|
|
46a0dc6dce | ||
|
|
30b2af820a | ||
|
|
e7d01b903f | ||
|
|
e4407dd73c | ||
|
|
2fd956d8d4 | ||
|
|
c0aac8e598 | ||
|
|
d46a44ac48 | ||
|
|
9b1bdd4b36 | ||
|
|
fd47920c63 | ||
|
|
088b8b3ec5 | ||
|
|
afd9b44dea | ||
|
|
b54db2ea07 | ||
|
|
3650d6eb4e | ||
|
|
05b74f3743 | ||
|
|
174cd7eaa0 | ||
|
|
3921e3db34 | ||
|
|
63bc7fe354 | ||
|
|
ba01e36cc2 | ||
|
|
40d2761bd8 | ||
|
|
4ff7fef3bb | ||
|
|
7be996c010 | ||
|
|
f4332475b5 | ||
|
|
4da00e8296 | ||
|
|
e8fae286be | ||
|
|
f451bb5f61 | ||
|
|
d8d7495767 | ||
|
|
e7ebdce60f | ||
|
|
fd61476106 | ||
|
|
4b4f6ac222 | ||
|
|
7b9699c5fa | ||
|
|
8a59558e2d | ||
|
|
5162472f16 | ||
|
|
1917bb69ed | ||
|
|
3b38153759 | ||
|
|
e06a17d929 | ||
|
|
71aea4b862 | ||
|
|
4b4818d819 | ||
|
|
c785e00a15 | ||
|
|
c6398e16b1 | ||
|
|
ccc7c4404d | ||
|
|
69d66a1d4d | ||
|
|
af81f6de70 | ||
|
|
f21dc7a96e | ||
|
|
cf07fcb4b1 | ||
|
|
740a7bcb45 | ||
|
|
0e2d2ea637 | ||
|
|
feaea49eac | ||
|
|
170f311101 | ||
|
|
0cadcdc097 | ||
|
|
337ebd3ce9 | ||
|
|
5d5920c5d0 | ||
|
|
8be65dee93 | ||
|
|
4dbd9dc264 | ||
|
|
2d0e45c46d | ||
|
|
d57b1aab10 | ||
|
|
cc84d6ea67 | ||
|
|
53a5f26430 | ||
|
|
a1ff4ae7b8 | ||
|
|
3251efa9c6 | ||
|
|
17a1cdb2cf | ||
|
|
1643f7df7a | ||
|
|
3c0344b954 | ||
|
|
22e8856b4d | ||
|
|
9bfafb88cb | ||
|
|
08b59aef8a | ||
|
|
fbc019171c | ||
|
|
e237abff84 | ||
|
|
718224f99a | ||
|
|
c0d1f22487 | ||
|
|
b2d6997eff | ||
|
|
e26f982c24 | ||
|
|
1b2fe69a18 | ||
|
|
c159a64b58 | ||
|
|
e091c9d6b4 | ||
|
|
67fd84fc1d | ||
|
|
57d3cfd67f | ||
|
|
6dd61626d2 | ||
|
|
1e99f887e7 | ||
|
|
78d10f30a0 | ||
|
|
7f0610d0bd | ||
|
|
4bef435e0e | ||
|
|
194baa0bd7 | ||
|
|
c8b8beb500 | ||
|
|
6786bab2ba | ||
|
|
566a7dabb2 | ||
|
|
a3e8de338a | ||
|
|
4f815ea978 | ||
|
|
417008a030 | ||
|
|
84c44c0099 | ||
|
|
2d6a856d61 | ||
|
|
011d7dc245 | ||
|
|
b2aa1798b1 | ||
|
|
5fb047930e | ||
|
|
c24e957f17 | ||
|
|
fd0b1ffc4d | ||
|
|
0bfe6394a4 | ||
|
|
9d025df9e3 | ||
|
|
2f5b11b295 | ||
|
|
c44826acc7 | ||
|
|
4386f2abc7 | ||
|
|
f217a10721 | ||
|
|
b8d695a4e1 | ||
|
|
44c2b4aa7f | ||
|
|
52ca531b7c | ||
|
|
d4254a40a9 | ||
|
|
052e3cc8eb | ||
|
|
56413ba3b4 | ||
|
|
71bb6108fb | ||
|
|
7d08dbb86c | ||
|
|
a8b65565dd | ||
|
|
54258e441d | ||
|
|
4ac223b684 | ||
|
|
707655daef | ||
|
|
70e83030a7 | ||
|
|
9787ce543d | ||
|
|
22595424a8 | ||
|
|
601189ea2d | ||
|
|
d3263dc35b | ||
|
|
e1c6b083f8 | ||
|
|
f56f5f234e | ||
|
|
4ca6da4a95 | ||
|
|
b0cbd90e64 | ||
|
|
9b6772a390 | ||
|
|
b7f0653a0e | ||
|
|
45bcd9fa2f | ||
|
|
20d98c7106 | ||
|
|
5ec658c55d | ||
|
|
64301d0d08 | ||
|
|
119ec16e5e | ||
|
|
decc0f18fc | ||
|
|
5a004425ca | ||
|
|
69f6500ba9 | ||
|
|
97980ffc7f | ||
|
|
f0fcf4aee0 | ||
|
|
838e5e1163 | ||
|
|
af0bdae675 | ||
|
|
0d45287057 | ||
|
|
09f8df9640 | ||
|
|
dbb99f31a7 | ||
|
|
c7da623d4b | ||
|
|
b44435ab8a | ||
|
|
c53df12ec1 | ||
|
|
13fae12f69 | ||
|
|
0120db0efc | ||
|
|
c4f50b52d7 | ||
|
|
242f397bfa | ||
|
|
f85d19b459 | ||
|
|
8f7f3627e0 | ||
|
|
8b134cf348 | ||
|
|
67de35ff29 | ||
|
|
774ee6a554 | ||
|
|
4be4ea3623 | ||
|
|
18fec7e202 | ||
|
|
072df5ecc9 | ||
|
|
4d7151aa5d | ||
|
|
185b2ce632 | ||
|
|
ce6772f2be | ||
|
|
d6e1a979e4 | ||
|
|
de8ec2beb0 | ||
|
|
342a796cc0 | ||
|
|
355754ed20 | ||
|
|
fbe07f1fce | ||
|
|
304432c197 | ||
|
|
5da7f6a488 | ||
|
|
f8c6b494aa | ||
|
|
1b573412d3 | ||
|
|
b400047045 | ||
|
|
51b1affbc5 | ||
|
|
903e9c994c | ||
|
|
fca68717ff | ||
|
|
22d6a4b255 | ||
|
|
26102a0970 | ||
|
|
add84bfddc | ||
|
|
dcd74d3e59 | ||
|
|
2684737b66 | ||
|
|
74181c0ec0 | ||
|
|
ebff9fbc31 | ||
|
|
97a41adf0c | ||
|
|
eef83a9fcb | ||
|
|
b62a90d54c | ||
|
|
b2ef77d92e | ||
|
|
b2b801a78b | ||
|
|
b4c12f6746 | ||
|
|
a4cc15c95c | ||
|
|
3c42a8e01c | ||
|
|
4a94a9fbd1 | ||
|
|
9f614fedec | ||
|
|
9ea4268b92 | ||
|
|
e417a0ca6f | ||
|
|
75769503ff | ||
|
|
589d67d8b7 | ||
|
|
3127e76f4b | ||
|
|
979e110a84 | ||
|
|
96785872cd | ||
|
|
ee71b9143f | ||
|
|
37a6ea63b1 | ||
|
|
56fe211b79 | ||
|
|
cf11a570e9 | ||
|
|
9fe0e711d6 | ||
|
|
b3452c1276 | ||
|
|
47f0ea69b8 | ||
|
|
667b96b495 | ||
|
|
3b25aea168 | ||
|
|
0affb4f936 | ||
|
|
8435df29c6 | ||
|
|
55c99dfaec | ||
|
|
c98fae59fc | ||
|
|
3c38a34ab2 | ||
|
|
ad7dcbc797 | ||
|
|
ad0306b00c | ||
|
|
d626e70287 | ||
|
|
3182475207 | ||
|
|
ea86e3e7b1 | ||
|
|
844549954a | ||
|
|
51fe417d58 | ||
|
|
0e718f0968 | ||
|
|
0d6d479d77 | ||
|
|
88e02322e5 | ||
|
|
5dea70b82e | ||
|
|
6b79af2b7c | ||
|
|
68718b6938 | ||
|
|
d70d71f574 | ||
|
|
f33517368e | ||
|
|
a48ca260bd | ||
|
|
71e04d9839 | ||
|
|
2970d59395 | ||
|
|
7073d18f23 | ||
|
|
23d8cd6c2a | ||
|
|
e70dd156b0 | ||
|
|
4469d062e1 | ||
|
|
bf70b4660e | ||
|
|
c0e07013e8 | ||
|
|
c6f30935a8 | ||
|
|
cb187fd900 | ||
|
|
3f23be2854 | ||
|
|
881ae5528d | ||
|
|
1a8354482a | ||
|
|
32eb1bf58f | ||
|
|
b2e17c3045 | ||
|
|
ac2c5f0201 | ||
|
|
1666716c31 | ||
|
|
5115fcb162 | ||
|
|
541ab8334d | ||
|
|
1db89d1589 | ||
|
|
965237e0da | ||
|
|
5698e425fd | ||
|
|
fbc8417263 | ||
|
|
ff1ddd0284 | ||
|
|
deaa31dca5 | ||
|
|
44e3a76881 | ||
|
|
f2efada0d4 | ||
|
|
5f00d6478a | ||
|
|
8b0dd9d224 | ||
|
|
7e5f1b14a3 | ||
|
|
caacd892cc | ||
|
|
25091fb2a0 | ||
|
|
dcdfe9bc34 | ||
|
|
f609036bee | ||
|
|
c39723c053 | ||
|
|
d2f400944d | ||
|
|
673125e64a | ||
|
|
e1592890cb | ||
|
|
f1b5f81eaf | ||
|
|
af53c230a1 | ||
|
|
ac9d0e17e4 | ||
|
|
5e498ca395 | ||
|
|
5c3acfefeb | ||
|
|
9b63e806dd | ||
|
|
bd842241a6 | ||
|
|
3815f0a132 | ||
|
|
d43b50b1ca | ||
|
|
14c2a16833 | ||
|
|
5ae9c5d947 | ||
|
|
2402f9774a | ||
|
|
3d3fe0df34 | ||
|
|
a320e1e535 | ||
|
|
8f0a7774f9 | ||
|
|
7f8b56eadd | ||
|
|
385d93e332 | ||
|
|
9ed804d9b1 | ||
|
|
03cfe23493 | ||
|
|
a97c23a4bd | ||
|
|
e1a2e11de4 | ||
|
|
5e49df8ed4 | ||
|
|
fa1ffa66d3 | ||
|
|
1aa57bf24f | ||
|
|
31dd0b75af | ||
|
|
46ecfd3c1a | ||
|
|
c31bc6deb7 | ||
|
|
fe45f1bf35 | ||
|
|
fc7f4ed904 | ||
|
|
33553839e2 | ||
|
|
1818e74f42 | ||
|
|
d72daca7bd | ||
|
|
c37202ecb9 | ||
|
|
1f5b19b81c | ||
|
|
8a98cb380e | ||
|
|
de5e2c60ae | ||
|
|
b31cc70235 | ||
|
|
78891a0ccc | ||
|
|
0b1d4d374a | ||
|
|
ac398998a2 | ||
|
|
21d69e3e6e | ||
|
|
33140259b8 | ||
|
|
723907464a | ||
|
|
bf4d91dd38 | ||
|
|
64fe56a9e1 | ||
|
|
39a05b7e4f | ||
|
|
e7f72c9555 | ||
|
|
a106fb451b | ||
|
|
b1300bdd79 | ||
|
|
be9707f8d2 | ||
|
|
702071553f | ||
|
|
47bd05e9a0 | ||
|
|
537c5f4b70 | ||
|
|
041033a51a | ||
|
|
2e191dc0e7 | ||
|
|
4a52814a79 | ||
|
|
69d80e2ded | ||
|
|
d84cd9466e | ||
|
|
627b921bca | ||
|
|
955afe0c9f | ||
|
|
316d5e5e77 | ||
|
|
1f051e6e14 | ||
|
|
f67da27d2f | ||
|
|
923739ebb4 | ||
|
|
97bc9f4730 | ||
|
|
bbbf612f29 | ||
|
|
d11fa573e6 | ||
|
|
6becd8fb13 | ||
|
|
a1ba0a89f8 | ||
|
|
a9aa52dc6a | ||
|
|
9595b30d6f | ||
|
|
f672e0cdb5 | ||
|
|
66bbef4ce0 | ||
|
|
dfe91d1766 | ||
|
|
cdde576182 | ||
|
|
82aeb70380 | ||
|
|
69ef1abdf6 | ||
|
|
cc6f0451e7 | ||
|
|
2c20ac6aa9 | ||
|
|
f8c751b3a4 | ||
|
|
547a271cee | ||
|
|
cd2444e546 | ||
|
|
6f1fb0352c | ||
|
|
4bf2c6b2e9 | ||
|
|
025b0be31b | ||
|
|
27551b23f3 | ||
|
|
ba08a21d21 | ||
|
|
48d625816c | ||
|
|
cee4f4ab6e | ||
|
|
de29613d91 | ||
|
|
9e3d43193d | ||
|
|
847ab4d18e | ||
|
|
183e124077 | ||
|
|
3142b237f5 | ||
|
|
969e45a599 | ||
|
|
df6c497ab0 | ||
|
|
12625cc00c | ||
|
|
bb94e02fad | ||
|
|
25126e2f99 | ||
|
|
d5d772d55e | ||
|
|
bdcd77d8e6 | ||
|
|
b9ebcbf555 | ||
|
|
c407a0bf19 | ||
|
|
7c77a5d3c8 | ||
|
|
ce2bf36aae | ||
|
|
3284f6af18 | ||
|
|
52b0f76eb2 | ||
|
|
e46b129c4f | ||
|
|
35787ef79b | ||
|
|
f029695db8 | ||
|
|
0ba628159f | ||
|
|
be65807370 | ||
|
|
158d37215a | ||
|
|
7ad25c90fa | ||
|
|
b06a326c7d | ||
|
|
25bdde85a9 | ||
|
|
334dcbd162 | ||
|
|
caed958455 | ||
|
|
d8905e2f87 | ||
|
|
b4e13b294d | ||
|
|
4fb3a312b0 | ||
|
|
82fadea1ed | ||
|
|
bb194dc6c6 | ||
|
|
9167b3aca1 | ||
|
|
76a25dc797 | ||
|
|
97de09c8f1 | ||
|
|
7595cb689a | ||
|
|
2b86470665 | ||
|
|
78423e9a14 | ||
|
|
ec59a626f2 | ||
|
|
1b14c035e7 | ||
|
|
ba34f8d389 | ||
|
|
b74e73058c | ||
|
|
c29597b3bc | ||
|
|
7c53d8c120 | ||
|
|
5d7a83468a | ||
|
|
a396837fa4 | ||
|
|
1fa3da68ba | ||
|
|
219726a9c5 | ||
|
|
81c0964e48 | ||
|
|
c9388ce767 | ||
|
|
7065538224 | ||
|
|
2a56f0cdf7 | ||
|
|
ace4837365 | ||
|
|
6417cf4d1b | ||
|
|
7fdd21b26d | ||
|
|
1731f7d321 | ||
|
|
8d39c1cc79 | ||
|
|
bc7e0cf09a | ||
|
|
7c29ea4d38 | ||
|
|
6c6c8bd454 | ||
|
|
81f780f1fb | ||
|
|
6838bae36e | ||
|
|
972a5299d5 | ||
|
|
b8149812cd | ||
|
|
01d4e87f57 | ||
|
|
f938a213fe | ||
|
|
df54c63b1b | ||
|
|
1810d9f318 | ||
|
|
29b9c3bb29 | ||
|
|
da2298988a | ||
|
|
f31ff7774a | ||
|
|
c6fafa1bc9 | ||
|
|
e8a8209a2b | ||
|
|
fa82859814 | ||
|
|
55e1386503 | ||
|
|
dc9565f54a | ||
|
|
c264bf04cc | ||
|
|
5c66e552d7 | ||
|
|
c4ebe352a4 | ||
|
|
1cba2e2339 | ||
|
|
79492aab36 | ||
|
|
e3454ed7fb | ||
|
|
8dcbe54e55 | ||
|
|
dac24a3d8a | ||
|
|
5c8eef2ab5 | ||
|
|
66c751be11 | ||
|
|
b4af24b7e2 | ||
|
|
7792a3a6e3 | ||
|
|
e57a5de33e | ||
|
|
ed705403ad | ||
|
|
fa899ab810 | ||
|
|
3fc0e6be90 | ||
|
|
fdcd99dfef | ||
|
|
d5ddd0f783 | ||
|
|
848d10594b | ||
|
|
caf3da2f66 | ||
|
|
f1b286469a | ||
|
|
46065199cd | ||
|
|
879fe3976d | ||
|
|
c1309e12f7 | ||
|
|
6bcc798a76 | ||
|
|
3e95d7f2d0 | ||
|
|
c3159e48c8 | ||
|
|
34be878257 | ||
|
|
87257ea6b3 | ||
|
|
8bc6001d27 | ||
|
|
e433098eb2 | ||
|
|
afdcdcfd54 | ||
|
|
4fc9a345bb | ||
|
|
9d4dc094a1 | ||
|
|
c06487c13b | ||
|
|
7a80661ad5 | ||
|
|
2fb527a63f | ||
|
|
99394e1011 | ||
|
|
3b1a566117 | ||
|
|
d58da49cee | ||
|
|
0fada5109a | ||
|
|
46ff7705ee | ||
|
|
eabcb2c8b0 | ||
|
|
ea60dfa44d | ||
|
|
53a82da3f3 | ||
|
|
b03bea14fa | ||
|
|
2f13fae6f0 | ||
|
|
a92af02ae8 | ||
|
|
4043124135 | ||
|
|
7b66e22bc6 | ||
|
|
5542e00b80 | ||
|
|
f3a1f46679 | ||
|
|
08673261b1 | ||
|
|
60c9b94656 | ||
|
|
f0e17fc20f | ||
|
|
de511e0348 | ||
|
|
ed8d94f69c | ||
|
|
1b3af684cb | ||
|
|
53fe10e4ad | ||
|
|
b4e1e54cf7 | ||
|
|
22db7ae85a | ||
|
|
6a88ce7d1e | ||
|
|
7e32c32057 | ||
|
|
c5737764b5 | ||
|
|
ddd6e9a48b | ||
|
|
d6fbfa55b6 | ||
|
|
abb11c80d1 | ||
|
|
ef0cb46b9b | ||
|
|
209a0f5a79 | ||
|
|
44e1ccec7e | ||
|
|
7c1f4b38f4 | ||
|
|
b9cfb5a7d8 | ||
|
|
1c8411f628 | ||
|
|
de9970412a | ||
|
|
a0e3a8b420 | ||
|
|
bc2ca1ef73 | ||
|
|
9a955859fd | ||
|
|
ecfe49adca | ||
|
|
7a75b2b8d0 | ||
|
|
127653b7d4 | ||
|
|
b7f2681007 | ||
|
|
12d6461bbe | ||
|
|
28a1101b91 | ||
|
|
8248601b72 | ||
|
|
2e78508016 | ||
|
|
d9120b8365 | ||
|
|
eb8e20c3ef | ||
|
|
cb0003d894 | ||
|
|
7becf808c7 | ||
|
|
13f8348568 | ||
|
|
d6e2ae292e | ||
|
|
e42f96b76d | ||
|
|
40a9196c7f | ||
|
|
0ca255b7b8 | ||
|
|
8ade4f1077 | ||
|
|
deae3e53f5 | ||
|
|
d74c909930 | ||
|
|
c0dac45fe1 | ||
|
|
eb5c4057a1 | ||
|
|
a080bd40fb | ||
|
|
b7b92eddbd | ||
|
|
e0ec397046 | ||
|
|
34e517de09 | ||
|
|
f40ba672db | ||
|
|
8ac440fd52 | ||
|
|
c3a8a4f81f | ||
|
|
7c56da26f6 | ||
|
|
97cd2dbc41 | ||
|
|
8affc297fc | ||
|
|
6d69812046 | ||
|
|
de8d16f5e7 | ||
|
|
b4712c6a93 | ||
|
|
3fc4f10248 | ||
|
|
ec55335092 | ||
|
|
af51300887 | ||
|
|
233cd27d70 | ||
|
|
c1f7db8275 | ||
|
|
0bf488ea49 | ||
|
|
bf8e0aa1ea | ||
|
|
4372138fdd | ||
|
|
8b179fb391 | ||
|
|
0b7cfba94a | ||
|
|
f43ec97e30 | ||
|
|
7521068ba3 | ||
|
|
a2ef66f197 | ||
|
|
3a694d7dfa | ||
|
|
cad108eca0 | ||
|
|
66eb186a74 | ||
|
|
6e1e77d46d | ||
|
|
e207c983c1 | ||
|
|
9a23511965 | ||
|
|
df7ab264ab | ||
|
|
9e1d418d7a | ||
|
|
ee9311c025 | ||
|
|
2ec4c38433 | ||
|
|
b6310d0365 | ||
|
|
77670b0f3e | ||
|
|
fd1fa7d551 | ||
|
|
0c5726d3ab | ||
|
|
5816de39ba | ||
|
|
80677a9d2b | ||
|
|
8d952c245f | ||
|
|
6d33a2e1a0 | ||
|
|
3bd4dea305 | ||
|
|
a4249fd573 | ||
|
|
ff05575b78 | ||
|
|
16e297ab61 | ||
|
|
447ce82721 | ||
|
|
86e4d79ffb | ||
|
|
11342ef97b | ||
|
|
48c17e2c3d | ||
|
|
36a69864e3 | ||
|
|
64b0e50609 | ||
|
|
806df9bc1e | ||
|
|
f98c613ecc | ||
|
|
642fcbbbfe | ||
|
|
58bb6725e4 | ||
|
|
3484ca5e64 | ||
|
|
0b1b7c36d2 | ||
|
|
8eb04cd80b | ||
|
|
8dfec65034 | ||
|
|
4a0e8139ea | ||
|
|
c8059a752f | ||
|
|
62a331a3dc | ||
|
|
90e0ce97e4 | ||
|
|
3b3c069c3b | ||
|
|
46b34d4b43 | ||
|
|
080ed2e8dd | ||
|
|
0c4cb309b0 | ||
|
|
8d5f800e2f | ||
|
|
e2a205ab22 | ||
|
|
21a499c726 | ||
|
|
e5f3750de2 | ||
|
|
4944fba3f7 | ||
|
|
65d21766b7 | ||
|
|
2a0521fba6 | ||
|
|
97cd7cc1c9 | ||
|
|
d3f60599e8 | ||
|
|
8728706237 | ||
|
|
c6c527e830 | ||
|
|
fc0a169a9a | ||
|
|
5b7366583d | ||
|
|
01e03ae2d8 | ||
|
|
8a1deee8d8 | ||
|
|
2e06316e31 | ||
|
|
6870af36b7 | ||
|
|
0f1dbffa40 | ||
|
|
cfb9cb6fe9 | ||
|
|
9de0d886eb | ||
|
|
5c24b80367 | ||
|
|
a477880edc | ||
|
|
00f5f54b77 | ||
|
|
1018c51359 | ||
|
|
8d8c345216 | ||
|
|
dd25ac03e4 | ||
|
|
3ff194dd61 | ||
|
|
215979c9e0 | ||
|
|
6d3acdcd2f | ||
|
|
9abe614ea8 | ||
|
|
36c171d78e | ||
|
|
c75c4421a7 | ||
|
|
55998f7481 | ||
|
|
d5acd7f338 | ||
|
|
d3cc05bdfc | ||
|
|
07ccd91022 | ||
|
|
edd0b661f3 | ||
|
|
4b0fabd7cb | ||
|
|
55e794dbe5 | ||
|
|
988dedd08d | ||
|
|
f66564273c | ||
|
|
dfc602159e | ||
|
|
9fde794858 | ||
|
|
ed1ddbce50 | ||
|
|
cda95afd3e | ||
|
|
0e40feb9af | ||
|
|
846306f85e | ||
|
|
a0aa090f2c | ||
|
|
460b5d6edb | ||
|
|
b9805f3f80 | ||
|
|
0069c4901f | ||
|
|
93b118bfa2 | ||
|
|
7c6bc95a84 | ||
|
|
ee8a1a3b68 | ||
|
|
5bca978444 | ||
|
|
347409e354 | ||
|
|
c284f3f226 | ||
|
|
cdd3c13ce9 | ||
|
|
f6dbaa7c31 | ||
|
|
a4553c970c | ||
|
|
38b6a43e26 | ||
|
|
121009dec4 | ||
|
|
510fb59e29 | ||
|
|
e4b3e838e2 | ||
|
|
4b70a16cf9 | ||
|
|
af0ee70ea3 | ||
|
|
ad39150565 | ||
|
|
686ef9e7f4 | ||
|
|
fac615108c | ||
|
|
ddfe89d916 | ||
|
|
b0948f81dd | ||
|
|
00f9e244f2 | ||
|
|
eb55f2d8f4 | ||
|
|
b50315d8a0 | ||
|
|
85286b8ca5 | ||
|
|
74944da211 | ||
|
|
c9a0a33fa2 | ||
|
|
b12be3188f | ||
|
|
26a28abcb5 | ||
|
|
5f1314cd66 | ||
|
|
0ad9d4bf16 | ||
|
|
621e5648e3 | ||
|
|
f0728fcf8f | ||
|
|
63ab886e9f | ||
|
|
7b4f1b165d | ||
|
|
8855eede5f | ||
|
|
69d49e137a | ||
|
|
94e17e0d88 | ||
|
|
5debc3c903 | ||
|
|
0ce332edca | ||
|
|
b122406683 | ||
|
|
35dc56d785 | ||
|
|
6cb13f4c44 | ||
|
|
26d5c99570 | ||
|
|
24836ccf6d | ||
|
|
7d22a011ab | ||
|
|
e9e5ae119f | ||
|
|
2c92904109 | ||
|
|
2fb6d0beb9 | ||
|
|
b9c17cab3c | ||
|
|
d2c3b79617 | ||
|
|
03b8222c9e | ||
|
|
57e109ff11 | ||
|
|
30614c5721 | ||
|
|
55521a2f4c | ||
|
|
8762e37e58 | ||
|
|
fba69f5651 | ||
|
|
bde1c6282e | ||
|
|
a24451b6d3 | ||
|
|
d0b8cded6b | ||
|
|
1e25c9da30 | ||
|
|
fe78e65b16 | ||
|
|
9e1d1f57f0 | ||
|
|
73acfa18a3 | ||
|
|
266d97f8f5 | ||
|
|
a70753e6d3 | ||
|
|
97dbb7bb49 | ||
|
|
79945ad473 | ||
|
|
1d7a3b4d0f | ||
|
|
5bf8b422f8 | ||
|
|
9633816d7a | ||
|
|
cc8708493e | ||
|
|
51b25fb3d8 | ||
|
|
b41a69da2d | ||
|
|
1ce92d1aeb | ||
|
|
496978abdd | ||
|
|
424bb17224 | ||
|
|
6d6a5f609a | ||
|
|
a296957771 | ||
|
|
fbe84e376c | ||
|
|
d30aa6d621 | ||
|
|
966063db0c | ||
|
|
13717e2e65 | ||
|
|
7aaaac42bc | ||
|
|
65930224ee | ||
|
|
97d1eedd5a | ||
|
|
11544f2717 | ||
|
|
590bd3dec9 | ||
|
|
74501f643c | ||
|
|
cebfe394ad | ||
|
|
2e037dcb93 | ||
|
|
3e41659095 | ||
|
|
d592d2c9cb | ||
|
|
78491b3a58 | ||
|
|
426f51db21 | ||
|
|
8a41ee95c7 | ||
|
|
5ae4e06770 | ||
|
|
683b3afbc1 | ||
|
|
1c86aee7a4 | ||
|
|
11f048c368 | ||
|
|
f0043468a0 | ||
|
|
3564f51fb5 | ||
|
|
df641261d6 | ||
|
|
f3486499ac | ||
|
|
a6081caf50 | ||
|
|
c77f7737a5 | ||
|
|
91cb433b66 | ||
|
|
2cb42b502c | ||
|
|
64bd4b3f74 | ||
|
|
41f2d2f789 | ||
|
|
913171f708 | ||
|
|
3f4daaf2ad | ||
|
|
cf32ba0149 | ||
|
|
6bec372684 | ||
|
|
620d8ce9ed | ||
|
|
bf8062ce7f | ||
|
|
350e50600d | ||
|
|
938abae4b5 | ||
|
|
264f881a81 | ||
|
|
d359764fba | ||
|
|
4a937ec3b8 | ||
|
|
0ded5b3ff3 | ||
|
|
c20a8ff53d | ||
|
|
2f38ed5e69 | ||
|
|
054fe34434 | ||
|
|
e686e3f6e9 | ||
|
|
a768f167cf | ||
|
|
cf996d2c4a | ||
|
|
9fef66ffcf | ||
|
|
1627922060 | ||
|
|
981db17b8f | ||
|
|
03a8340a85 | ||
|
|
036197fac3 | ||
|
|
52dd348289 | ||
|
|
f4c1b20ec2 | ||
|
|
08762a101c | ||
|
|
3b5c889040 | ||
|
|
0171204e50 | ||
|
|
dd82b15b78 | ||
|
|
3d91b10927 | ||
|
|
65b3bf0d4c | ||
|
|
4c0b2372c7 | ||
|
|
54110c98d9 | ||
|
|
a2c593bc2c | ||
|
|
de0122dc17 | ||
|
|
2c43a9d209 | ||
|
|
6da70168a6 | ||
|
|
0199515cef | ||
|
|
37705e712b | ||
|
|
d2b0404188 | ||
|
|
80f9a20bfd | ||
|
|
94a9551ffa | ||
|
|
4419f7ca0f | ||
|
|
19f77cfff5 | ||
|
|
3cdee749c6 | ||
|
|
d03d288a98 | ||
|
|
b8d60a9cf1 | ||
|
|
c5dbb1c933 | ||
|
|
85342f1e31 | ||
|
|
c1f9ae8208 | ||
|
|
bd1672621c | ||
|
|
2d6cda7f32 | ||
|
|
2c8690ee39 | ||
|
|
6c98480a1e | ||
|
|
98cc7eb149 | ||
|
|
6278930aef | ||
|
|
0b57b3136c | ||
|
|
46b7a2d17c | ||
|
|
588af1f6af | ||
|
|
34f99c4a79 | ||
|
|
a0d4242da4 | ||
|
|
447c3639e7 | ||
|
|
f0e276c63a | ||
|
|
7d4e693d20 | ||
|
|
03372c9b29 | ||
|
|
6d0ba4b3bd | ||
|
|
6622f015ab | ||
|
|
d6ec5e40cc | ||
|
|
c44b80b6b6 | ||
|
|
9db814f70d | ||
|
|
d7f9054108 | ||
|
|
2df9204104 | ||
|
|
b02ac3a733 | ||
|
|
ed4f7046d3 | ||
|
|
ad1bc1e0b8 | ||
|
|
70a5402509 | ||
|
|
2ea51b02cc | ||
|
|
036fc561a2 | ||
|
|
a8185407fa | ||
|
|
1cc85aad64 | ||
|
|
067cd4b4fe | ||
|
|
6d68b1f5ad | ||
|
|
e8b3e2f248 | ||
|
|
d5aad39b3f | ||
|
|
cce9ac28c9 | ||
|
|
49e3a91d67 | ||
|
|
76b6a1771b | ||
|
|
c88cb5c8b5 | ||
|
|
efd503f84a | ||
|
|
7ba52ae729 | ||
|
|
8ebda7ac02 | ||
|
|
43a8b46203 | ||
|
|
d1af5163eb | ||
|
|
ee6eccbfe1 | ||
|
|
d37cfc69d9 | ||
|
|
3a6c8c92b3 | ||
|
|
e17b67e6f2 | ||
|
|
c0e0ede09f | ||
|
|
a4425471fd | ||
|
|
b4e2240ede | ||
|
|
539b872e02 | ||
|
|
2ff6c4c3fc | ||
|
|
f2c0ea7fa4 | ||
|
|
8686e31271 | ||
|
|
0bf0f6d721 | ||
|
|
3ef0c1c88a | ||
|
|
5b115ddb74 | ||
|
|
604e39b413 | ||
|
|
f3253f4f5c | ||
|
|
2fb2ddb9b4 | ||
|
|
7e4d6198d4 | ||
|
|
8c31f2ee44 | ||
|
|
9a026e51bd | ||
|
|
50982b668b | ||
|
|
c6c988ae28 | ||
|
|
306d84828d | ||
|
|
216ad777de | ||
|
|
4710e744dc | ||
|
|
0b3029dd3f | ||
|
|
41b8b3256d | ||
|
|
42f2bd926b | ||
|
|
197d07cc85 | ||
|
|
c9fd0659c2 | ||
|
|
fa2fbf0c60 | ||
|
|
c3fe29455b | ||
|
|
df5aca9348 | ||
|
|
ab0b36a53f | ||
|
|
29a44b84d5 | ||
|
|
e5b77b180a | ||
|
|
fc1cdfc913 | ||
|
|
8c5027abb9 | ||
|
|
333daf33a3 | ||
|
|
064f2b5787 | ||
|
|
13ac72239a | ||
|
|
818216374c | ||
|
|
5a9cf5722f | ||
|
|
a5ba0c27ae | ||
|
|
f6d3953bc6 | ||
|
|
c9a5135e23 | ||
|
|
ab326aea4c | ||
|
|
7cf5988099 | ||
|
|
35a30fbd6d | ||
|
|
6608a7aa98 | ||
|
|
803a7d06e3 | ||
|
|
be4685589a | ||
|
|
bf7d62affb | ||
|
|
718b73a0ba | ||
|
|
c2a43f70f2 | ||
|
|
c222da9dd6 | ||
|
|
55e366f29c | ||
|
|
4e71aad124 | ||
|
|
a03f2fe937 | ||
|
|
5710992156 | ||
|
|
0ed9be4665 | ||
|
|
d665c3a75f | ||
|
|
48f3c70013 | ||
|
|
8a4ec8f562 | ||
|
|
1a652a9736 | ||
|
|
15fed8d17f | ||
|
|
396f9b3a12 | ||
|
|
1f69200d06 | ||
|
|
0e0d625adb | ||
|
|
638dbbecbc | ||
|
|
9f89a83c27 | ||
|
|
178af9de56 | ||
|
|
e7854bec09 | ||
|
|
9b9612e09c | ||
|
|
d2d02bf91d | ||
|
|
860c5030d2 | ||
|
|
2d54fea90c | ||
|
|
5ee0254ce5 | ||
|
|
37019dab1c | ||
|
|
2b31f28f8f | ||
|
|
8931e31991 | ||
|
|
813efbe1d3 | ||
|
|
7790df0df6 | ||
|
|
c2b32df22b | ||
|
|
479a2e0383 | ||
|
|
471cf1d51a | ||
|
|
ecdaad2fd6 | ||
|
|
3e20622bd5 | ||
|
|
8a4a28bd33 | ||
|
|
8fe59ed888 | ||
|
|
1927213174 | ||
|
|
cb8e147212 | ||
|
|
07baed89ed | ||
|
|
af1cf3400e | ||
|
|
eb53670676 | ||
|
|
709dc73c27 | ||
|
|
14e09d2ca8 | ||
|
|
0353b0ddd3 | ||
|
|
f2ba08f77f | ||
|
|
1d7d8cb4d2 | ||
|
|
6e9cfd8a33 | ||
|
|
2a9fd34a03 | ||
|
|
b1111c96ca | ||
|
|
55383155e5 | ||
|
|
bb1502a9d7 | ||
|
|
40ee30ecde | ||
|
|
4ff00359b6 | ||
|
|
f433fa4187 | ||
|
|
594ead00e8 | ||
|
|
5adf3b8865 | ||
|
|
4fc52cd08e | ||
|
|
4af47f0c26 | ||
|
|
9d3510a1e4 | ||
|
|
18f6ad9583 | ||
|
|
4c70ea5e09 | ||
|
|
d32c060e05 | ||
|
|
caa3d1ab5d | ||
|
|
d3e809da38 | ||
|
|
5ab892d009 | ||
|
|
54dbc0fdf8 | ||
|
|
003f91d43d | ||
|
|
83806a4d77 | ||
|
|
c4324f1db2 | ||
|
|
b9c3e0e640 | ||
|
|
60e51a238d | ||
|
|
fff4c9c672 | ||
|
|
ab17f41652 | ||
|
|
18ab569b2d | ||
|
|
2951d34dc0 | ||
|
|
0cc5379caa | ||
|
|
f6fcfa831c | ||
|
|
c93fc3ec76 | ||
|
|
7b5f012f79 | ||
|
|
22cee5d2d6 | ||
|
|
0f18dff464 | ||
|
|
e38aeefb5c | ||
|
|
baa983ac33 | ||
|
|
cd65c66cf9 | ||
|
|
dc272a680b | ||
|
|
6f64fc266d | ||
|
|
73af3b17b1 | ||
|
|
8b2884e40f | ||
|
|
f0c22f390d | ||
|
|
11f2cd4515 | ||
|
|
5ce7984a2b | ||
|
|
9699059226 | ||
|
|
9941c3f045 | ||
|
|
25e7eeac8f | ||
|
|
277e82bd03 | ||
|
|
a1f1afe3ed | ||
|
|
0f523de212 | ||
|
|
47f12c453a | ||
|
|
dfcff3f0fc | ||
|
|
522f2ee3b3 | ||
|
|
8ce1fdb5bb | ||
|
|
a0efdac8ce | ||
|
|
22bc54f974 | ||
|
|
e240621a72 | ||
|
|
35c2a72ad2 | ||
|
|
10ec1a659f | ||
|
|
1fb34e42a6 | ||
|
|
7082000e66 | ||
|
|
79fff367c2 | ||
|
|
9cbf2a82ec | ||
|
|
6a40807330 | ||
|
|
8d6e33c2cf | ||
|
|
085874d5f3 | ||
|
|
94fb7e32ea | ||
|
|
042f7ec791 | ||
|
|
e4f47a05f6 | ||
|
|
bbf37e5229 | ||
|
|
454aa8433b | ||
|
|
bbf1c6a8df | ||
|
|
8e5eff5e1e | ||
|
|
e64fa71185 | ||
|
|
c8845643e5 | ||
|
|
371ff5e726 | ||
|
|
19520d8d35 | ||
|
|
abb11a7c0e | ||
|
|
2ac74356bd | ||
|
|
004f13f0fc | ||
|
|
395a97ef07 | ||
|
|
01b0cfc8ab | ||
|
|
f3758e4af0 | ||
|
|
2563324ed8 | ||
|
|
d91ccd4003 | ||
|
|
15ddb8e2ea | ||
|
|
c056c93e19 | ||
|
|
9e32a5bfa1 | ||
|
|
cd5c41f351 | ||
|
|
b780d707ab | ||
|
|
84ae563368 | ||
|
|
dddc7c6edb | ||
|
|
bd8d82809b | ||
|
|
51b7142805 | ||
|
|
6c9ef76b95 | ||
|
|
a024ec5b27 | ||
|
|
2212e959ac | ||
|
|
d4d027159f | ||
|
|
a8a581acae | ||
|
|
9e4fa02cdb | ||
|
|
6d6e07604e | ||
|
|
dc499089e9 | ||
|
|
f4b8e19c7f | ||
|
|
1809c0e675 | ||
|
|
d11d69958f | ||
|
|
6d2733405d | ||
|
|
2dc2d162bc | ||
|
|
56b2b02637 | ||
|
|
d031c26229 | ||
|
|
4046fcf971 | ||
|
|
7a4fd2ec01 | ||
|
|
73731ba155 | ||
|
|
8781a148db | ||
|
|
0e978a0d99 | ||
|
|
ac46ede170 | ||
|
|
ad669fc23a | ||
|
|
b9d3bc5b44 | ||
|
|
fa2ed81485 | ||
|
|
ea4a723379 | ||
|
|
71bcdb91c8 | ||
|
|
08294dc4d6 | ||
|
|
09712603c4 | ||
|
|
2fb7ccc8f0 | ||
|
|
31bfe50831 | ||
|
|
9aa3b5b78c | ||
|
|
7480f55e53 | ||
|
|
5fd82e829b | ||
|
|
43ebec1812 | ||
|
|
5cdf02f840 | ||
|
|
824e081005 | ||
|
|
fc992ba380 | ||
|
|
264070bfc7 | ||
|
|
a91509ba72 | ||
|
|
0dfe2429bc | ||
|
|
f1ad2e1fae | ||
|
|
c51679810a | ||
|
|
468ad1a2d5 | ||
|
|
bf8fbc2c0e | ||
|
|
0ed8ae28e7 | ||
|
|
f76ad8912c | ||
|
|
83e7d442fb | ||
|
|
76252659fd | ||
|
|
19036348a5 | ||
|
|
7efea4bb23 | ||
|
|
63ce244359 | ||
|
|
0bdf9538d0 | ||
|
|
b88e23892f | ||
|
|
bcf1e178a1 | ||
|
|
fe889b8428 | ||
|
|
cde7498c8e | ||
|
|
a27feb4157 | ||
|
|
a93c835557 | ||
|
|
5cd5821c18 | ||
|
|
3912e29eb7 | ||
|
|
0bad04d374 | ||
|
|
50c3a64553 | ||
|
|
cd8492dd7b | ||
|
|
79e160a46b | ||
|
|
761b3b3646 | ||
|
|
937f027f3c | ||
|
|
da14538299 | ||
|
|
02fbf766ad | ||
|
|
b13bef7f45 | ||
|
|
5e1aadba80 | ||
|
|
44e0bbf342 | ||
|
|
a7ed3379df | ||
|
|
19849e66d4 | ||
|
|
e9dac2fddc | ||
|
|
e61fe48b4d | ||
|
|
7e8b52ad70 | ||
|
|
d5a5f9572e | ||
|
|
fe4f7f8b0f | ||
|
|
4e3f80749f | ||
|
|
ff8c340330 | ||
|
|
039109ed56 | ||
|
|
f3f34e9ef5 | ||
|
|
2f39102026 | ||
|
|
6793eb383c | ||
|
|
2caceda8c4 | ||
|
|
238dc3a5b6 | ||
|
|
390ff30690 | ||
|
|
e1cf187cfe | ||
|
|
8c01df7828 | ||
|
|
ff8faa4cd7 | ||
|
|
b9aa64fd25 | ||
|
|
8dfd53620c | ||
|
|
0090aee0e5 | ||
|
|
230dea1243 | ||
|
|
3453bfa513 | ||
|
|
d0f047dfe7 | ||
|
|
8e7c454de0 | ||
|
|
68c75c7eb1 | ||
|
|
31ae260282 | ||
|
|
8b443b94ea | ||
|
|
6ec9c844e4 | ||
|
|
3d3b03e1e4 | ||
|
|
4d194cb50c | ||
|
|
b0d2bf4afe | ||
|
|
8f73bc3b4c | ||
|
|
90495b614f | ||
|
|
f03bcc24ad | ||
|
|
6646155712 | ||
|
|
9d72208d9e | ||
|
|
e84e703211 | ||
|
|
0497c0742f | ||
|
|
573e2b0012 | ||
|
|
c4b72fcc79 | ||
|
|
a2d7716331 | ||
|
|
67b5ebdb76 | ||
|
|
4c2ce2b45b | ||
|
|
3b2bade2f2 | ||
|
|
cdeb28a793 | ||
|
|
61918a1efa | ||
|
|
963adb5230 | ||
|
|
8f8a1ecf18 | ||
|
|
b9343b458f | ||
|
|
ac85fa2fc3 | ||
|
|
b7855857b5 | ||
|
|
d957c4373b | ||
|
|
f485d8f548 | ||
|
|
b994e235f3 | ||
|
|
2b1aea80ed | ||
|
|
53d8083343 | ||
|
|
d30c125ab7 | ||
|
|
9e2c75b548 | ||
|
|
aa54b23713 | ||
|
|
dc8e955c4f | ||
|
|
96b22a16eb | ||
|
|
5fbbfbcbe3 | ||
|
|
faf98dacf6 | ||
|
|
86b47a528a | ||
|
|
cf6c21a0d2 | ||
|
|
b1d900210a | ||
|
|
963fc4cebc | ||
|
|
80adaa700c | ||
|
|
dfead460ca | ||
|
|
6f21f8a402 | ||
|
|
abfc99308d | ||
|
|
955c87ef30 | ||
|
|
b4df62bec1 | ||
|
|
14d2fa3895 | ||
|
|
005c5309c4 | ||
|
|
c44d9ae923 | ||
|
|
a487259e8e | ||
|
|
37308e6760 | ||
|
|
4ce374be25 | ||
|
|
8b8e8a94ff | ||
|
|
3c9fdde24b | ||
|
|
578a46fbda | ||
|
|
6fb2088d5f | ||
|
|
49d9eb687d | ||
|
|
654c933e30 | ||
|
|
83a86aacb5 | ||
|
|
f231809e22 | ||
|
|
2c8e0a6914 | ||
|
|
496816acff | ||
|
|
78b52f5716 | ||
|
|
2ca108820f | ||
|
|
dc6bd715b2 | ||
|
|
18a1e01d64 | ||
|
|
15e1078d01 | ||
|
|
06b0c7e928 | ||
|
|
3924c2f2bd | ||
|
|
7625d900d3 | ||
|
|
53dc1f2055 | ||
|
|
e706fa4a58 | ||
|
|
65e81e4034 | ||
|
|
1f2f55bea3 | ||
|
|
4b78790096 | ||
|
|
236e129e7a | ||
|
|
d200619774 | ||
|
|
f35ea486a7 | ||
|
|
a48cd7cb1d | ||
|
|
d0f13223bc | ||
|
|
7ae284f432 | ||
|
|
df872b8223 | ||
|
|
150a8a12a0 | ||
|
|
d8823ed45e | ||
|
|
9a63b3147f | ||
|
|
3f586ff4ab | ||
|
|
c4d4cfe9dc | ||
|
|
08cd112585 | ||
|
|
566087b518 | ||
|
|
f4a7cca075 | ||
|
|
d9d50fdf54 | ||
|
|
4c18ddf549 | ||
|
|
7c7b9a4be1 | ||
|
|
9faedbf516 | ||
|
|
ba45dedbd5 | ||
|
|
7815138386 | ||
|
|
47e4f4dae1 | ||
|
|
9b3197c6e8 | ||
|
|
44355f8eef | ||
|
|
45058dfa79 | ||
|
|
83f9cb88cf | ||
|
|
c851ed9d60 | ||
|
|
5f19f65ef2 | ||
|
|
8ca8cd046f | ||
|
|
6832dda2fa | ||
|
|
782bc6c03a | ||
|
|
b158f1cbe6 | ||
|
|
944a114400 | ||
|
|
5a7120e163 | ||
|
|
1f58232e87 | ||
|
|
0d3827989d | ||
|
|
07ff3020cf | ||
|
|
af4748d92b | ||
|
|
240a0b9c93 | ||
|
|
6421c865f5 | ||
|
|
06de5c7ffe | ||
|
|
ccae9ea6a8 | ||
|
|
8692a5fd06 | ||
|
|
dcbe62b9b9 | ||
|
|
9bed99482a | ||
|
|
fb201976b8 | ||
|
|
bb745a8036 | ||
|
|
a330eda4b6 | ||
|
|
dcfdd144d8 | ||
|
|
0fd3ed593c | ||
|
|
83d424f2f4 | ||
|
|
c16c90c00a | ||
|
|
8087a5914c | ||
|
|
03eccd4958 | ||
|
|
6d3f272551 | ||
|
|
7ffb7c19fd | ||
|
|
f545f18c2d | ||
|
|
33d2577fb5 | ||
|
|
3be22bd43b | ||
|
|
094b876a38 | ||
|
|
97f8e9ce1c | ||
|
|
385be63126 | ||
|
|
7710528f01 | ||
|
|
c25462d924 | ||
|
|
9b45d240bb | ||
|
|
8bd27db727 | ||
|
|
83a7985a97 | ||
|
|
2d54a45a80 | ||
|
|
813a5f1e1f | ||
|
|
c7d7757dbd | ||
|
|
d7b6996bcf | ||
|
|
61705e4d22 | ||
|
|
6a1730956e | ||
|
|
df8a6529ac | ||
|
|
97a29f9c50 | ||
|
|
9395d58669 | ||
|
|
f9a0bbbc20 | ||
|
|
ccfd369a77 | ||
|
|
2ec1c3b56c | ||
|
|
dbeb626f32 | ||
|
|
8fd78d3819 | ||
|
|
b56b08387d | ||
|
|
34b16699fa | ||
|
|
75dfa5af7e | ||
|
|
e983032762 | ||
|
|
f5c5709cd9 | ||
|
|
fb874e1d65 | ||
|
|
6495508194 | ||
|
|
482626b9b8 | ||
|
|
9f01040d46 | ||
|
|
cdf298bafb | ||
|
|
a2f9f9320b | ||
|
|
0a48f613ec | ||
|
|
19f2d69be8 | ||
|
|
241de27c75 | ||
|
|
df8dafc5ca | ||
|
|
d01b7ac682 | ||
|
|
3161723c8b | ||
|
|
a907811b22 | ||
|
|
f1d298450d | ||
|
|
53eb66e5c4 | ||
|
|
907f576010 | ||
|
|
f24c2146e0 | ||
|
|
c342b58a87 | ||
|
|
be8feb7ee8 | ||
|
|
b32eb2bfc1 | ||
|
|
4375a03f38 | ||
|
|
ad9b7d700a | ||
|
|
460272291f | ||
|
|
f567dafe62 | ||
|
|
3c86c57765 | ||
|
|
dc2f77e019 | ||
|
|
80693d8338 | ||
|
|
72e5c4300c | ||
|
|
6e7168b3e9 | ||
|
|
31892e1d68 | ||
|
|
aa3099ce09 | ||
|
|
c6b90b9068 | ||
|
|
47fe5c201c | ||
|
|
f7d19f5a3a | ||
|
|
d42f7daef7 | ||
|
|
53363e6b80 | ||
|
|
7ba0573702 | ||
|
|
777a99fe07 | ||
|
|
3b392b2dd9 | ||
|
|
6009929a3b | ||
|
|
c1c9de4546 | ||
|
|
c08ae001a6 | ||
|
|
6c2c4d4428 | ||
|
|
e692e7cd9e | ||
|
|
f0a62e83c8 | ||
|
|
a01225db39 | ||
|
|
b36f6b67e6 | ||
|
|
782de8743f | ||
|
|
c42ac967ea | ||
|
|
e379fcf2cf | ||
|
|
89678fca47 | ||
|
|
e378f79d2b | ||
|
|
fba165408c | ||
|
|
dd168373a1 | ||
|
|
076e60378a | ||
|
|
526af777d4 | ||
|
|
f121558668 | ||
|
|
640ba7d69e | ||
|
|
bc4498e018 | ||
|
|
805d03125b | ||
|
|
7499f0811b | ||
|
|
37e0566957 | ||
|
|
1fbaff9f81 | ||
|
|
c3943d21d0 | ||
|
|
a7158ec69c | ||
|
|
f66906d54d | ||
|
|
85afef9981 | ||
|
|
bd463a038c | ||
|
|
eeb1a284a8 | ||
|
|
b38cc75f17 | ||
|
|
dd11528160 | ||
|
|
912d6f442a | ||
|
|
346621ed21 | ||
|
|
941f5a8ecb | ||
|
|
76e11e6f64 | ||
|
|
3c558ebbee | ||
|
|
eba7b16ccf | ||
|
|
466cd43277 | ||
|
|
47acbefa57 | ||
|
|
d9cf34ab8c | ||
|
|
9dc7d2a081 | ||
|
|
438708ea15 | ||
|
|
835840e8da | ||
|
|
d13e0762d3 | ||
|
|
ae8f6a6db5 | ||
|
|
608c5fd516 | ||
|
|
b5bd58b2b6 | ||
|
|
9785fd0333 | ||
|
|
b02a1ee037 | ||
|
|
5de43fca4e | ||
|
|
46fdbd629d | ||
|
|
2f4902a478 | ||
|
|
7e58c5009e | ||
|
|
39009dcfb9 | ||
|
|
a19ea4b662 | ||
|
|
63bc12d3f1 | ||
|
|
b9c2236885 | ||
|
|
450ae723cb | ||
|
|
2ac5ee4062 | ||
|
|
0d436b5f11 | ||
|
|
ca6983139e | ||
|
|
9f56c92497 | ||
|
|
113cecc4f0 | ||
|
|
7ac1176120 | ||
|
|
09c23a564d | ||
|
|
a969d3ff1d | ||
|
|
b6324d0007 | ||
|
|
ba27b4be69 | ||
|
|
7c3ef56332 | ||
|
|
7b9286b2c2 | ||
|
|
50d2b4e0b5 | ||
|
|
f1988a9e20 | ||
|
|
a24a3c565e | ||
|
|
20d87297b2 | ||
|
|
049df99afc | ||
|
|
6dcdf4ff45 | ||
|
|
00fd33b635 | ||
|
|
f2dc526fc8 | ||
|
|
e5491198f6 | ||
|
|
4cab45c759 | ||
|
|
fa53a4c057 | ||
|
|
edd0c5af5a | ||
|
|
2fb269a938 | ||
|
|
3eac6aeb99 | ||
|
|
ec64646fee | ||
|
|
5371268f8f | ||
|
|
2decb30d4e | ||
|
|
c0bbc609be | ||
|
|
f6be426aa0 | ||
|
|
17b5c8ac6f | ||
|
|
b18d0d75fd | ||
|
|
77e13e459b | ||
|
|
06647bdd0a | ||
|
|
24183d9a39 | ||
|
|
1e080cc258 | ||
|
|
dc5854689b | ||
|
|
ed70b9d4d0 | ||
|
|
c7a9801db7 | ||
|
|
85521f88b2 | ||
|
|
75ca0f23ac | ||
|
|
eba73f6844 | ||
|
|
cf45da33f6 | ||
|
|
fb7498a8ec | ||
|
|
574f9afa3d | ||
|
|
3751ac1784 | ||
|
|
af759dcf42 | ||
|
|
47426c28e1 | ||
|
|
49f7775d2d | ||
|
|
67c20c0715 | ||
|
|
c50cb65019 | ||
|
|
23b4d2fd1d | ||
|
|
dd18703b50 | ||
|
|
b1ba298ffc | ||
|
|
992324b425 | ||
|
|
56e10f9bce | ||
|
|
69664a1bb3 | ||
|
|
1f5727fe9d | ||
|
|
b52a1ed60a | ||
|
|
c3f1820ebc | ||
|
|
4afa6a2887 | ||
|
|
1254efaddb | ||
|
|
adeace8f62 | ||
|
|
4447180d5a | ||
|
|
41beccbe3c | ||
|
|
a4958e76c1 | ||
|
|
a9e264dd84 | ||
|
|
51988dba09 | ||
|
|
39c4c23200 | ||
|
|
63cbb64341 | ||
|
|
c0cb0c35e2 | ||
|
|
9db6d6f4ef | ||
|
|
57bd6bc2cd | ||
|
|
e5deb2b3c3 | ||
|
|
fc64fa49ac | ||
|
|
5dfd36af6a | ||
|
|
1778177195 | ||
|
|
ac9d36e444 | ||
|
|
fcda00c3d8 | ||
|
|
28d5db3bca | ||
|
|
8fcd67e82f | ||
|
|
710290ad1d | ||
|
|
aa262ecf0e | ||
|
|
338e6d7f72 | ||
|
|
4ef9470466 | ||
|
|
0e4d589d80 | ||
|
|
835244f92d | ||
|
|
2f498162b0 | ||
|
|
93cf3bd922 | ||
|
|
d3ae3525b8 | ||
|
|
c8a2a78319 | ||
|
|
1f12642af2 | ||
|
|
9111c2e702 | ||
|
|
0e388fd21c | ||
|
|
41c6364f6c | ||
|
|
12134d2043 | ||
|
|
83c41c69be | ||
|
|
31f4214b5d | ||
|
|
9f708ad0c8 | ||
|
|
a2760c6ca3 | ||
|
|
98a362136b | ||
|
|
bcbf9f7dfd | ||
|
|
1a9a48c5f2 | ||
|
|
32bd1dfd53 | ||
|
|
77cf992224 | ||
|
|
0c11267045 | ||
|
|
ee6f24b48a | ||
|
|
eb959b3879 | ||
|
|
f31798bbb4 | ||
|
|
a1aaa4495c | ||
|
|
be17b8215c | ||
|
|
15bdcf79e6 | ||
|
|
09aa9e2a04 | ||
|
|
c98fa8168b | ||
|
|
32a9c2ce49 | ||
|
|
c7cd72c682 | ||
|
|
144b66c4da | ||
|
|
7c7eccf1f2 | ||
|
|
5de73f6c25 | ||
|
|
6f47364392 | ||
|
|
9a5546c8e9 | ||
|
|
f1972ff336 | ||
|
|
cb6793f56b | ||
|
|
2aedbc2e42 | ||
|
|
f0b73dc9f5 | ||
|
|
354708dbc2 | ||
|
|
3059db8515 | ||
|
|
498e8124f6 | ||
|
|
18afd2d84f | ||
|
|
6d3e9df89f | ||
|
|
d08cb20376 | ||
|
|
c778ef1004 | ||
|
|
50c2226dd3 | ||
|
|
9fa973debe | ||
|
|
07e66dd2b4 | ||
|
|
4d8434d1b6 | ||
|
|
ce4bf4aca5 | ||
|
|
21111755cf | ||
|
|
7fda0cd7d9 | ||
|
|
a2d33112b8 | ||
|
|
2c7f6d8bfe | ||
|
|
5ec7e885f1 | ||
|
|
3338cd073d | ||
|
|
9a71bb17fd | ||
|
|
841463da8e | ||
|
|
71db1fc142 | ||
|
|
bc0cc34420 | ||
|
|
611174b0af | ||
|
|
9c76c3ef8e | ||
|
|
8f8c4b44f1 | ||
|
|
3ae818860b | ||
|
|
188ad03c17 | ||
|
|
a151ceccc6 | ||
|
|
cb81f86434 | ||
|
|
d7f1193f22 | ||
|
|
9017b1ad3d | ||
|
|
14f86043cf | ||
|
|
042af51751 | ||
|
|
936abc381b | ||
|
|
e882af9f8d | ||
|
|
9c5eca9131 | ||
|
|
919596aba4 | ||
|
|
eb3a32e853 | ||
|
|
3af34d61d3 | ||
|
|
bc8022f49f | ||
|
|
4eee750d4c | ||
|
|
f6a8d4c074 | ||
|
|
bb05e07e4e | ||
|
|
8d30feaf88 | ||
|
|
76685e6e51 | ||
|
|
09b243e689 | ||
|
|
a8b36b231c | ||
|
|
d5f639fc50 | ||
|
|
9fc3f8593e | ||
|
|
58cac0ca39 | ||
|
|
304a120429 | ||
|
|
c418bca461 | ||
|
|
0441d4a5d1 | ||
|
|
5eb255a649 | ||
|
|
605f362ab6 | ||
|
|
a257f5993a | ||
|
|
987aaa0e19 | ||
|
|
b0e7c3e3e7 | ||
|
|
5aa21c363d | ||
|
|
6aaa2eb4d0 | ||
|
|
6163215bbe | ||
|
|
4788f842c0 | ||
|
|
b94c15bdcc | ||
|
|
ebbe0babdb | ||
|
|
187cda0c39 | ||
|
|
f13e363a87 | ||
|
|
83e6955dce | ||
|
|
749e056618 | ||
|
|
c17efcf422 | ||
|
|
3ede624759 | ||
|
|
67f1e04f3b | ||
|
|
a4be3bceec | ||
|
|
56391df345 | ||
|
|
4f4032c053 | ||
|
|
195ca70278 | ||
|
|
776b1b723e | ||
|
|
baef719908 | ||
|
|
6d8126e498 | ||
|
|
6b4e437c93 | ||
|
|
853d28860a | ||
|
|
62a1824400 | ||
|
|
b3a4ce4e98 | ||
|
|
42812a8dc0 | ||
|
|
6e9cb27e46 | ||
|
|
1aba75e3e8 | ||
|
|
0f577e0c94 | ||
|
|
7170536021 | ||
|
|
1cb6464948 | ||
|
|
e36746d367 | ||
|
|
371282fe7a | ||
|
|
96f74f9da8 | ||
|
|
4eeab947dd | ||
|
|
e7cc4e4faf | ||
|
|
ecd4722b7c | ||
|
|
5a92b339a4 | ||
|
|
cb5642945a | ||
|
|
b84063bc3f | ||
|
|
426d71cb4f | ||
|
|
b2be475f93 | ||
|
|
ad79e142ca | ||
|
|
0d6d221568 | ||
|
|
863f3f6b47 | ||
|
|
ff82c59903 | ||
|
|
27cdafb2d0 | ||
|
|
2aa093b65c | ||
|
|
1e984e78ca | ||
|
|
520d6a9d93 | ||
|
|
00220a9f2c | ||
|
|
6faff7c344 | ||
|
|
0e5dd3d557 | ||
|
|
2ddae698bb | ||
|
|
99c06b5cda | ||
|
|
343c0fdef7 | ||
|
|
017e3a156e | ||
|
|
12b217c8ec | ||
|
|
6a9c4380f3 | ||
|
|
a75368e2e8 | ||
|
|
13f6b037e2 | ||
|
|
c2da8c2d54 | ||
|
|
5b16d4790c | ||
|
|
101a044219 | ||
|
|
7bfb2e3a78 | ||
|
|
ab2050dc59 | ||
|
|
98d22f9510 | ||
|
|
e146b539f5 | ||
|
|
d1094e11a0 | ||
|
|
02e94cdb1c | ||
|
|
c8d994a97d | ||
|
|
e007f69c71 | ||
|
|
08527075b7 | ||
|
|
6347849cd0 | ||
|
|
b32a75858a | ||
|
|
d6d46697d0 | ||
|
|
3a64e6a711 | ||
|
|
ca90af4fa5 | ||
|
|
e822b2d43b | ||
|
|
3a16677ebf | ||
|
|
d60aa9a80c | ||
|
|
26a115adcf | ||
|
|
aed0e8790e | ||
|
|
cecae0f965 | ||
|
|
55bf6450e7 | ||
|
|
95be4a61ec | ||
|
|
abef3f59be | ||
|
|
9619fa66eb | ||
|
|
d096f69c78 | ||
|
|
f52ef98cee | ||
|
|
a458c4a905 | ||
|
|
85c8a6780a | ||
|
|
99deb8c670 | ||
|
|
331036f86d | ||
|
|
291f377d40 | ||
|
|
4d4e758bf3 | ||
|
|
bfc236fca3 | ||
|
|
b648b392b6 | ||
|
|
89516e6ee1 | ||
|
|
0c3093f331 | ||
|
|
ebdcfb5227 | ||
|
|
fc332bcfbd | ||
|
|
e96cdbf67c | ||
|
|
2287b06aeb | ||
|
|
1335aee54b | ||
|
|
6058910b49 | ||
|
|
b60afdb619 | ||
|
|
3834e7bc33 | ||
|
|
0942071517 | ||
|
|
7b887f065d | ||
|
|
e6fb3bcffb | ||
|
|
9448a477d2 | ||
|
|
2bc2c4717e | ||
|
|
b82f495ec7 | ||
|
|
1130f4fef5 | ||
|
|
a8da321883 | ||
|
|
32e63cd130 | ||
|
|
3df28a8a6a | ||
|
|
10442239f1 | ||
|
|
a9e95fa43b | ||
|
|
c92fd79f35 | ||
|
|
0342b0a89f | ||
|
|
341de42692 | ||
|
|
f43ee4075d | ||
|
|
79148d2940 | ||
|
|
bd10c2f828 | ||
|
|
2f7c076a50 | ||
|
|
880c5c8083 | ||
|
|
7596e3a157 | ||
|
|
cb9683a7fd | ||
|
|
0d4d7e0880 | ||
|
|
bb080130b9 | ||
|
|
f229f791a9 | ||
|
|
e694b41a94 | ||
|
|
31746ce692 | ||
|
|
53fbfc7d15 | ||
|
|
78835073db | ||
|
|
c11ca94870 | ||
|
|
c1dc74fc8b | ||
|
|
e2a6f292a2 | ||
|
|
b0a4b7ab85 | ||
|
|
8d6b909b93 | ||
|
|
303be86291 | ||
|
|
113d7ce98f | ||
|
|
2c84f3ed1f | ||
|
|
c1d24944dc | ||
|
|
35b6a70724 | ||
|
|
54d9b283fa | ||
|
|
90a13bd791 | ||
|
|
15cfe8ebf1 | ||
|
|
8c4a48d9d0 | ||
|
|
8fff6e9baf | ||
|
|
7342058e64 | ||
|
|
083fc61dfb | ||
|
|
502d444ebd | ||
|
|
c3582d4058 | ||
|
|
37d9204ad9 | ||
|
|
a3500e807a | ||
|
|
1442262376 | ||
|
|
33ac70aec3 | ||
|
|
5005cb606f | ||
|
|
c458346593 | ||
|
|
c64e8d4b53 | ||
|
|
e5dfa19ec9 | ||
|
|
0e395569ee | ||
|
|
262d796356 | ||
|
|
cf5a086263 | ||
|
|
d14ba6ac53 | ||
|
|
7b1902183c | ||
|
|
cb6be74851 | ||
|
|
9e03c66529 | ||
|
|
f6b190bb5a | ||
|
|
3f89fea65a | ||
|
|
c8b9c5a54e | ||
|
|
fd268a0479 | ||
|
|
648d6432eb | ||
|
|
df46fb8c68 | ||
|
|
d9cd75c426 | ||
|
|
87560d943c | ||
|
|
8d0a0e8ab1 | ||
|
|
55794d9534 | ||
|
|
84dcd6fe2f | ||
|
|
88cc1ee35d | ||
|
|
6e89ad3401 | ||
|
|
1ea38d2f93 | ||
|
|
1d4d7e96fa | ||
|
|
67eb966a75 | ||
|
|
ceef24834c | ||
|
|
cb2a7f0820 | ||
|
|
8f29574b16 | ||
|
|
c0ec479e60 | ||
|
|
54101a1c9b | ||
|
|
43613498db | ||
|
|
ac841ca4e9 | ||
|
|
95d86758ee | ||
|
|
ed79715841 | ||
|
|
b01d7db409 | ||
|
|
e5fe145f80 | ||
|
|
2642fde0f8 | ||
|
|
f682bf642f | ||
|
|
5ed69a5a58 | ||
|
|
a4b6b2464c | ||
|
|
4f89245570 | ||
|
|
5236bb279d | ||
|
|
967fec2ae5 | ||
|
|
d7052d09ff | ||
|
|
acc06d772a | ||
|
|
f360fba47f | ||
|
|
de0b93381c | ||
|
|
42d39d59dd | ||
|
|
bfed78a996 | ||
|
|
9c55bd59a1 | ||
|
|
e89d7a7756 | ||
|
|
41cd0c272b | ||
|
|
6506f6d99e | ||
|
|
fffa01933d | ||
|
|
acafb1b53a | ||
|
|
c437f0b14b | ||
|
|
20a07c174c | ||
|
|
6e6165796c | ||
|
|
f6ca5d814c | ||
|
|
45ed62931b | ||
|
|
9c54291d04 | ||
|
|
e8d592cdc6 | ||
|
|
24a0015148 | ||
|
|
b0e34edf99 | ||
|
|
c5f922c5db | ||
|
|
ebdd57a2fe | ||
|
|
b21057d166 | ||
|
|
4f486bc444 | ||
|
|
9447796d8e | ||
|
|
c7157ca90c | ||
|
|
250ec12646 | ||
|
|
2d9cff3af6 | ||
|
|
95bc4c5eeb | ||
|
|
30a18fdaeb | ||
|
|
13774cf48a | ||
|
|
69d2048ccc | ||
|
|
d4dac214ab | ||
|
|
5605ba32e3 | ||
|
|
59d6e59f97 | ||
|
|
f90f1ef8e0 | ||
|
|
69b901a5b6 | ||
|
|
af2e866947 | ||
|
|
17eaf63c6d | ||
|
|
e2176a6521 | ||
|
|
2e6b50335f | ||
|
|
380bee97dd | ||
|
|
1e60c4c4d2 | ||
|
|
be0051ee69 | ||
|
|
c79a7b5055 | ||
|
|
08388fea5a | ||
|
|
8bc706a94e | ||
|
|
6f9ac01e71 | ||
|
|
19a92a4493 | ||
|
|
2b66d5d6c0 | ||
|
|
0ada1dfc3f | ||
|
|
645075f910 | ||
|
|
9fd031c896 | ||
|
|
e14737dd88 | ||
|
|
d1bca6364a | ||
|
|
8eb283df2c | ||
|
|
b4d40c7501 | ||
|
|
ee8f53dd77 | ||
|
|
d85910c17f | ||
|
|
42a91219cb | ||
|
|
cdd033ffb0 | ||
|
|
493fa7d8fe | ||
|
|
c605b3e232 | ||
|
|
ae55c70ac5 | ||
|
|
769870b493 | ||
|
|
765f57b658 | ||
|
|
a59d056ad2 | ||
|
|
f7e6dabf6b | ||
|
|
baaec57d5c | ||
|
|
26de26f88f | ||
|
|
4fd878447e | ||
|
|
8cdee9c0f4 | ||
|
|
dafe6b09c5 | ||
|
|
2ea549ce5f | ||
|
|
341f511bbd | ||
|
|
54f162e523 | ||
|
|
b5261abb6b | ||
|
|
9bc613e4a7 | ||
|
|
5967b48348 | ||
|
|
b0f49be19e | ||
|
|
35f395a0e4 | ||
|
|
61852aaddc | ||
|
|
7450df8104 | ||
|
|
52e7d9a672 | ||
|
|
8f96f5f20f | ||
|
|
b2313beaf4 | ||
|
|
c064c90ee9 | ||
|
|
2e3f575f9c | ||
|
|
dc0b03e54e | ||
|
|
bd08d06de3 | ||
|
|
8568441221 | ||
|
|
a3adc9c1b6 | ||
|
|
e3ec325619 | ||
|
|
3c848736a7 | ||
|
|
3bba51d5d9 | ||
|
|
72c83f5e43 | ||
|
|
159150c319 | ||
|
|
bc87d9ed3d | ||
|
|
e188b9ff41 | ||
|
|
db531495b8 | ||
|
|
ecb23d15c4 | ||
|
|
bd047cbb4f | ||
|
|
008d2ba0d3 | ||
|
|
45bd0854b6 | ||
|
|
3e0c35bd0f | ||
|
|
7945178f3a | ||
|
|
19f08888e8 | ||
|
|
c515aaac5a | ||
|
|
0b3b0ab68b | ||
|
|
c24e1eacb9 | ||
|
|
9a3b736174 | ||
|
|
e0ed254252 | ||
|
|
9005682cf1 | ||
|
|
3df82a757d | ||
|
|
3fd7f9efdd | ||
|
|
d457423c24 | ||
|
|
f051d0880e | ||
|
|
ed501ea37e | ||
|
|
20dae3758a | ||
|
|
a04e17c4ea | ||
|
|
fc149fdada | ||
|
|
19dfe4b01d | ||
|
|
c4a3e170e2 | ||
|
|
dfd6025d04 | ||
|
|
01c14bc640 | ||
|
|
c435647589 | ||
|
|
c50cf23b7b | ||
|
|
540783a6dd | ||
|
|
25c8b4b34f | ||
|
|
c0a89a7988 | ||
|
|
07d9e9b71e | ||
|
|
269f4e8da8 | ||
|
|
481c3d536b | ||
|
|
7e5db250d3 | ||
|
|
970bfbe151 | ||
|
|
7d98bb216a | ||
|
|
e4b7d06f35 | ||
|
|
b19c004680 | ||
|
|
7bc91bf6c6 | ||
|
|
c49cd02365 | ||
|
|
992f4192bf | ||
|
|
921ab3ce68 | ||
|
|
69942c9a81 | ||
|
|
fb5158630a | ||
|
|
34c29b3406 | ||
|
|
c0796da7b9 | ||
|
|
83651a7d6a | ||
|
|
10d57705a0 | ||
|
|
71998e06cf | ||
|
|
a16594ed7b | ||
|
|
f7fce3cd68 | ||
|
|
ba850790ed | ||
|
|
abc1e83319 | ||
|
|
99a06ce4ea | ||
|
|
31441868e0 | ||
|
|
5d82dddfb1 | ||
|
|
d568b56c5e | ||
|
|
3ab0c12bf1 | ||
|
|
ed74f42323 | ||
|
|
15d84dbb4e | ||
|
|
65fa0411b4 | ||
|
|
408833daef | ||
|
|
bb35b3e3b2 | ||
|
|
4a3e1fb0cb | ||
|
|
fe68261bc2 | ||
|
|
1f2c6c77fd | ||
|
|
08e1101c1f | ||
|
|
72847b9b26 | ||
|
|
4b2d40d3b5 | ||
|
|
72d7fe2f7a | ||
|
|
43f7f6c355 | ||
|
|
a53c104db1 | ||
|
|
2a0bd1adc7 | ||
|
|
a2631759c0 | ||
|
|
2b87cabbb4 | ||
|
|
d8465ce767 | ||
|
|
60f80e2698 | ||
|
|
c782c2ec1c | ||
|
|
f0d778ce49 | ||
|
|
a3c224e57a | ||
|
|
b727245834 | ||
|
|
6b19e61bd0 | ||
|
|
38ce0cfd9a | ||
|
|
61a39e04fc | ||
|
|
ea3aa6803a | ||
|
|
3a20d7dacb | ||
|
|
e5837b4ee9 | ||
|
|
d1f31c5143 | ||
|
|
4af41e9bfb | ||
|
|
121110a485 | ||
|
|
d41a414b5c | ||
|
|
9bd3cca7c4 | ||
|
|
18cbddff6a | ||
|
|
df414dab02 | ||
|
|
904207ba8f | ||
|
|
44618d5765 | ||
|
|
70cfd54ad4 | ||
|
|
62bf0a2bc9 | ||
|
|
c9289155b4 | ||
|
|
cd67ec6e69 | ||
|
|
cd6261d477 | ||
|
|
3b60aad487 | ||
|
|
493780efab | ||
|
|
9290e508c6 | ||
|
|
a1ebb14495 | ||
|
|
eb9a524ea1 | ||
|
|
0caa731291 | ||
|
|
704fbf499b | ||
|
|
04fd24e068 | ||
|
|
dc6a83c030 | ||
|
|
bcecbd051b | ||
|
|
6607224493 | ||
|
|
6224edd6ce | ||
|
|
9598b11c77 | ||
|
|
fa95f743f3 | ||
|
|
e2c46d14f0 | ||
|
|
bd3471b3d1 | ||
|
|
1b88d18d61 | ||
|
|
b4de17d504 | ||
|
|
f90fac0e55 | ||
|
|
9fd92bf884 | ||
|
|
117204a784 | ||
|
|
e7834de929 | ||
|
|
d5d5de55ae | ||
|
|
143c4d5efc | ||
|
|
13adc44867 | ||
|
|
87693d84cb | ||
|
|
6ed33fcc6d | ||
|
|
2e59cc4807 | ||
|
|
4ddd65a4c4 | ||
|
|
bf6bafa3ac | ||
|
|
24f1174b16 | ||
|
|
098caa9979 | ||
|
|
b608d4a5ea | ||
|
|
4d32c47bee | ||
|
|
ec54b50c67 | ||
|
|
387c690530 | ||
|
|
536e24b024 | ||
|
|
1b05cd81f0 | ||
|
|
db181e2a36 | ||
|
|
f41ca2e5e8 | ||
|
|
a8c6a641d7 | ||
|
|
474c372b17 | ||
|
|
5b9b45814f | ||
|
|
01cd5476a0 | ||
|
|
027b9e9dc3 | ||
|
|
197f576cab | ||
|
|
0b8facc66f | ||
|
|
7a0d95c612 | ||
|
|
975b82f09b | ||
|
|
f496cc229b | ||
|
|
9894eeb8e9 | ||
|
|
129e950c59 | ||
|
|
c90a75ebc5 | ||
|
|
1d6eca76f8 | ||
|
|
6555d86328 | ||
|
|
c71f2794eb | ||
|
|
ca18f1fad6 | ||
|
|
ead9b1041c | ||
|
|
1eebbfe2bc | ||
|
|
d30c8b321c | ||
|
|
083500fc0e | ||
|
|
fd6e9a1e66 | ||
|
|
8c45aa480b | ||
|
|
d704afa0e9 | ||
|
|
2ec857ef8d | ||
|
|
ba02ebc3dc | ||
|
|
ac752a46bc | ||
|
|
398ec3be5a | ||
|
|
6c997978bc | ||
|
|
642e7fada5 | ||
|
|
12493779b9 | ||
|
|
7142131f3d | ||
|
|
5bdf78d5ec | ||
|
|
60a4138d50 | ||
|
|
cb52be6475 | ||
|
|
c2ec40e6ce | ||
|
|
87fd05afb0 | ||
|
|
45b5bae7d7 | ||
|
|
d0b918e083 | ||
|
|
0231f8da1b | ||
|
|
3eda5a2e85 | ||
|
|
18d6fd72de | ||
|
|
d286b33601 | ||
|
|
a749d43897 | ||
|
|
08506f160d | ||
|
|
b902377304 | ||
|
|
1c903450c8 | ||
|
|
f950e282a6 | ||
|
|
4da982b253 | ||
|
|
b1b78dca47 | ||
|
|
0ada5a7734 | ||
|
|
cc10641f38 | ||
|
|
9df3e6a538 | ||
|
|
133aa7be4a | ||
|
|
6555659e82 | ||
|
|
b1f7d5e33b | ||
|
|
17bf3b7115 | ||
|
|
ff9af83358 | ||
|
|
5f2326e911 | ||
|
|
4d2dd337f6 | ||
|
|
f43c79c101 | ||
|
|
b42045f3f7 | ||
|
|
3301738b84 | ||
|
|
d4ac11cd4f | ||
|
|
8b953bbde6 | ||
|
|
acd69b1c70 | ||
|
|
f3caa9292f | ||
|
|
071b527b66 | ||
|
|
ebad1ec552 | ||
|
|
af451bc530 | ||
|
|
d1b17df38c | ||
|
|
b18d7fb550 | ||
|
|
980a663c19 | ||
|
|
65c107fc5d | ||
|
|
da6ea27454 | ||
|
|
58a5d93214 | ||
|
|
5b848fbc47 | ||
|
|
8522a11bcb | ||
|
|
d944f81163 | ||
|
|
c67e7fbcea | ||
|
|
a80d8d55c4 | ||
|
|
9026069f79 | ||
|
|
c9421cbfcd | ||
|
|
5399b989c0 | ||
|
|
9d1fd38b69 | ||
|
|
a4156b71fa | ||
|
|
fa4871574a | ||
|
|
a59df2cf74 | ||
|
|
051a863ff5 | ||
|
|
8d544ce80b | ||
|
|
cc7b0f2e8f | ||
|
|
b4ef4a9e28 | ||
|
|
9be1453886 | ||
|
|
89cd25ab15 | ||
|
|
d624310be1 | ||
|
|
9c8a22832c | ||
|
|
55a0e1d2ff | ||
|
|
e638de5c7c | ||
|
|
0aa36899a8 | ||
|
|
ac2f814eb4 | ||
|
|
27e5c42023 | ||
|
|
6b0418a74a | ||
|
|
a0b2b78962 | ||
|
|
d1ffffab04 | ||
|
|
f9dff6ffc4 | ||
|
|
88847df70b | ||
|
|
492ee57b8f | ||
|
|
5c85bf22bb | ||
|
|
527af3b69f | ||
|
|
6b6beb588c | ||
|
|
dc1288d319 | ||
|
|
87226b6f44 | ||
|
|
3b6f020f8a | ||
|
|
93d77e2354 | ||
|
|
85ed376748 | ||
|
|
bfc7704ca1 | ||
|
|
e41abe2d83 | ||
|
|
de9fb7777b | ||
|
|
24a5adc898 | ||
|
|
0a3f6c49f8 | ||
|
|
8262070f5c | ||
|
|
9c4164e7a3 | ||
|
|
1dab47176b | ||
|
|
dfa50c90b3 | ||
|
|
ff88482034 | ||
|
|
7e225688cb | ||
|
|
5678bf10fd | ||
|
|
989d539af3 | ||
|
|
d017a8f9f7 | ||
|
|
5a34f53689 | ||
|
|
96f076983e | ||
|
|
a322b3ad68 | ||
|
|
9814fc2e1c | ||
|
|
ec2d358ae3 | ||
|
|
6c8eab7af5 | ||
|
|
b810d10e80 | ||
|
|
72c4efbc39 | ||
|
|
2a932597e4 | ||
|
|
4eed514e37 | ||
|
|
0337dc23c3 | ||
|
|
2b3b03c3c6 | ||
|
|
6a059bfab7 | ||
|
|
0b87387fab | ||
|
|
8c34aff1c5 | ||
|
|
cc827b139d | ||
|
|
c6e1a96882 | ||
|
|
c3410e722e | ||
|
|
534e2a25de | ||
|
|
d2c820b5d7 | ||
|
|
ff7e729b84 | ||
|
|
a21606e348 | ||
|
|
4bd657160d | ||
|
|
be8d812919 | ||
|
|
e40d25e4bd | ||
|
|
2a7a26482a | ||
|
|
3d6cdfa636 | ||
|
|
15a2b7d69a | ||
|
|
9ff8433f21 | ||
|
|
1c7d51a2c4 | ||
|
|
49020208f9 | ||
|
|
6f32fe27f8 | ||
|
|
7a16db9ad3 | ||
|
|
2f8a29b5a0 | ||
|
|
64b5ccc524 | ||
|
|
4fc4edc7a0 | ||
|
|
358edfb21f | ||
|
|
577daf5457 | ||
|
|
afa3bb4191 | ||
|
|
e81810d845 | ||
|
|
c57ebffe6f | ||
|
|
e281133f12 | ||
|
|
92878558c6 | ||
|
|
ec449158c6 | ||
|
|
eefa004b8f | ||
|
|
77a75ed365 | ||
|
|
364ec2a694 | ||
|
|
9a8a707016 | ||
|
|
7a5f014014 | ||
|
|
5ca5a504a4 | ||
|
|
cb45c8feac | ||
|
|
7d79d73b58 | ||
|
|
7c426db36a | ||
|
|
744638ed08 | ||
|
|
9bc7cd7904 | ||
|
|
d83bbfb1d5 | ||
|
|
4ad9e82f50 | ||
|
|
677c7edf3f | ||
|
|
e56af4967c | ||
|
|
1f7af35368 | ||
|
|
08ab4abd43 | ||
|
|
a810eb29db | ||
|
|
3881324007 | ||
|
|
af3b356d70 | ||
|
|
24676eea71 | ||
|
|
7e2eb997a8 | ||
|
|
ec570c46bf | ||
|
|
8eedfe4bc6 | ||
|
|
800fb81d1b | ||
|
|
e020f5849c | ||
|
|
698784e103 | ||
|
|
f7345ffaac | ||
|
|
b7faa4a7f2 | ||
|
|
0fcfb80be4 | ||
|
|
38a9b7166b | ||
|
|
3b28f52ff7 | ||
|
|
7725fe338e | ||
|
|
2ed66f6e8b | ||
|
|
9aaf789c21 | ||
|
|
d5cf339b83 | ||
|
|
6bc7b56e6e | ||
|
|
e4db6d47c2 | ||
|
|
ce4e00e5ae | ||
|
|
06ca2ef726 | ||
|
|
8d853a6d58 | ||
|
|
de768aefc3 | ||
|
|
4b284f6687 | ||
|
|
d0948e5586 | ||
|
|
b0a45e5b93 | ||
|
|
6f91331626 | ||
|
|
4ecb1bb2ed | ||
|
|
3bcca99cba | ||
|
|
5612a59b30 | ||
|
|
88ea66b4c9 | ||
|
|
b61399fbde | ||
|
|
a8db2bcf10 | ||
|
|
e14f4c5db1 | ||
|
|
1948b0c7c7 | ||
|
|
4b4b0e630e | ||
|
|
d9071a80a0 | ||
|
|
969740a263 | ||
|
|
0222d90fa3 | ||
|
|
a133e018cc | ||
|
|
c2d1ae06c5 | ||
|
|
59e41f195b | ||
|
|
7987d4e5ce | ||
|
|
a8e331a778 | ||
|
|
eb97652537 | ||
|
|
0a4fe7ed97 | ||
|
|
676e893c14 | ||
|
|
e37056192b | ||
|
|
8321f6bfe3 | ||
|
|
b3d1c238eb | ||
|
|
61d9bd7e5e | ||
|
|
1fbb6e8734 | ||
|
|
59de6b505a | ||
|
|
ea1411cd07 | ||
|
|
c5fd64c72a | ||
|
|
45f442bd73 | ||
|
|
b8a4adbdc7 | ||
|
|
47fdcebb01 | ||
|
|
8cdd8de360 | ||
|
|
7402aea9f2 | ||
|
|
300c711af1 | ||
|
|
39b8bbc39b | ||
|
|
90f96af720 | ||
|
|
710b2b5fdc | ||
|
|
a577b81eb3 | ||
|
|
a5478b0712 | ||
|
|
12587d8295 | ||
|
|
e17bb4ff11 | ||
|
|
aba19841ee | ||
|
|
0288dba46c | ||
|
|
5a306785ba | ||
|
|
c200b95f6a | ||
|
|
2cccd621ea | ||
|
|
385b18f588 | ||
|
|
bf1f9f4b95 | ||
|
|
4c3271728d | ||
|
|
57231ae75d | ||
|
|
97c2a70593 | ||
|
|
485346f0e5 | ||
|
|
a8d4c3a567 | ||
|
|
dfb3a13246 | ||
|
|
f84eb9ed47 | ||
|
|
8136c5f3de | ||
|
|
45669e08c6 | ||
|
|
a5db69e1af | ||
|
|
8aceef20e1 | ||
|
|
7e3c71ed19 | ||
|
|
9d09bee6fb | ||
|
|
cd6ee373ff | ||
|
|
4d0acc9b02 | ||
|
|
393fbf1b66 | ||
|
|
3324b03a5d | ||
|
|
eb91f9922d | ||
|
|
9a7420ccd0 | ||
|
|
be72120311 | ||
|
|
c452c3a101 | ||
|
|
0b3bb66708 | ||
|
|
d0d0fa4d10 | ||
|
|
6222ed622f | ||
|
|
1a03e98057 | ||
|
|
46cea93fc3 | ||
|
|
d64b8fd9d8 | ||
|
|
c051daee2f | ||
|
|
ae70d10996 | ||
|
|
52e6399e02 | ||
|
|
ac05f62f2f | ||
|
|
4d935efd09 | ||
|
|
fa8cc7976a | ||
|
|
ee4e34bf6d | ||
|
|
c8e0f8b149 | ||
|
|
b47188763c | ||
|
|
5e5c9df5c4 | ||
|
|
1a97f599dd | ||
|
|
3b264c9572 | ||
|
|
144c096ae6 | ||
|
|
adbcd320b2 | ||
|
|
17ba44056e | ||
|
|
502abade7c | ||
|
|
b746c9018e | ||
|
|
92af641827 | ||
|
|
b5606a247d | ||
|
|
d62baf5a5d | ||
|
|
e17567866a | ||
|
|
76f9596f22 | ||
|
|
2a3a713811 | ||
|
|
175ebb3cd8 | ||
|
|
95367a4a63 | ||
|
|
8950c3c4c8 | ||
|
|
2d1abd099d | ||
|
|
a894db35fd | ||
|
|
328a14014c | ||
|
|
315a2c63fa | ||
|
|
ca4ea7649d | ||
|
|
08c877ec7b | ||
|
|
212ad45be4 | ||
|
|
e9b37c7578 | ||
|
|
1438cecfad | ||
|
|
49824ce1a6 | ||
|
|
bc0ec9dc07 | ||
|
|
5957b9f155 | ||
|
|
72e6e828f1 | ||
|
|
01b4393fa7 | ||
|
|
bf2a5386f9 | ||
|
|
fb4d4a609b | ||
|
|
1cddb2aa88 | ||
|
|
aac9679282 | ||
|
|
90472685e8 | ||
|
|
7bb764b3e4 | ||
|
|
1aed9c545f | ||
|
|
c937e49689 | ||
|
|
0d860516ac | ||
|
|
4ced1d65b4 | ||
|
|
92540d5e85 | ||
|
|
ea982a627e | ||
|
|
835ecac8db | ||
|
|
c3bbb48041 | ||
|
|
2e842f0146 | ||
|
|
8de2fb9009 | ||
|
|
17e177405a | ||
|
|
ef67561fb3 | ||
|
|
df97effb9c | ||
|
|
8317960f81 | ||
|
|
065bf54094 | ||
|
|
f36acc27e5 | ||
|
|
491ad6de95 | ||
|
|
3eedf8ed1b | ||
|
|
75b260e495 | ||
|
|
2351948291 | ||
|
|
538e518d76 | ||
|
|
de955dacc4 | ||
|
|
19ed63129e | ||
|
|
2e744a1c1b | ||
|
|
89534b88b1 | ||
|
|
c067808b54 | ||
|
|
59ae79d8fb | ||
|
|
ad1c5e1884 | ||
|
|
9958cedd89 | ||
|
|
d1aaed4430 | ||
|
|
89debc87b2 | ||
|
|
9d2c81ea54 | ||
|
|
44765907b3 | ||
|
|
4a85f3d499 | ||
|
|
f99b5ad463 | ||
|
|
8fc631269b | ||
|
|
a1975583a7 | ||
|
|
1c628e7883 | ||
|
|
3605168e85 | ||
|
|
f86fca2739 | ||
|
|
0410748e2d | ||
|
|
2172878f21 | ||
|
|
d3a51fbfa1 | ||
|
|
aae2405de4 | ||
|
|
2b578367a9 | ||
|
|
f9b028b78c | ||
|
|
572aa4e98f | ||
|
|
864275f07e | ||
|
|
998a7c8cb0 | ||
|
|
6d7a04228f | ||
|
|
4a8c2e8a13 | ||
|
|
f3a60edc5d | ||
|
|
1e1146d61d | ||
|
|
832e1d8cb8 | ||
|
|
4936211a9c | ||
|
|
f0d731009f | ||
|
|
a6248d03e5 | ||
|
|
a934cf4947 | ||
|
|
c498b7090e | ||
|
|
ca9e45e8af | ||
|
|
97096696a2 | ||
|
|
27fb3763b4 | ||
|
|
da43c70488 | ||
|
|
76ade0cb4d | ||
|
|
09e1526bca | ||
|
|
7d1fbeb708 | ||
|
|
15217c705e | ||
|
|
9f108e87eb | ||
|
|
1e786d6d8b | ||
|
|
0557eb9b93 | ||
|
|
241f6f3068 | ||
|
|
326656245a | ||
|
|
177ec92c39 | ||
|
|
711dacae5f | ||
|
|
c19183118e | ||
|
|
0af132d0c6 | ||
|
|
83c0e77ca8 | ||
|
|
1e315b5a33 | ||
|
|
6e0e0767f9 | ||
|
|
6df50399a9 | ||
|
|
7b9a8998cf | ||
|
|
7de5253318 | ||
|
|
eaf4a71d32 | ||
|
|
4dd40034ed | ||
|
|
030476d335 | ||
|
|
45aae5e322 | ||
|
|
9763839ed1 | ||
|
|
7ee10e06be | ||
|
|
8f3ea1d0c5 | ||
|
|
b9b87f7d8e | ||
|
|
c9b6e82e2c | ||
|
|
c8f969b4a2 | ||
|
|
ecd1c77f48 | ||
|
|
ad93d2fe4d | ||
|
|
5a4d401582 | ||
|
|
590c069158 | ||
|
|
94185e3f70 | ||
|
|
9adcd16ec6 | ||
|
|
74bcd898e7 | ||
|
|
296808d4d3 | ||
|
|
b7519cb834 | ||
|
|
7d6c050048 | ||
|
|
16f9a2e6b7 | ||
|
|
cbfe7f5822 | ||
|
|
895cd88761 | ||
|
|
f2ea18b0ba | ||
|
|
162f6b9d5c | ||
|
|
4f8ae3ccbe | ||
|
|
acd9be3863 | ||
|
|
ddf18ae34c | ||
|
|
0da61ec47e | ||
|
|
80230414a2 | ||
|
|
ce7c0d176b | ||
|
|
4ec79732f1 | ||
|
|
cc3c314988 | ||
|
|
8553a89af2 | ||
|
|
566321d67a | ||
|
|
a2778bf06d | ||
|
|
29eff23490 | ||
|
|
4ebaa82563 | ||
|
|
69911209ea | ||
|
|
92688c89ef | ||
|
|
fe04f8ce6b | ||
|
|
b72641693d | ||
|
|
0c6ee52cfc | ||
|
|
1f87094628 | ||
|
|
3b22018296 | ||
|
|
5be437deb9 | ||
|
|
8d098194dd | ||
|
|
256525bfa2 | ||
|
|
79e4f30f69 | ||
|
|
884637468e | ||
|
|
6fd7810d89 | ||
|
|
2f97d0d9b1 | ||
|
|
1bb9c57767 | ||
|
|
d880b8b8f2 | ||
|
|
7129f518a4 | ||
|
|
fa6f1c2fb1 | ||
|
|
2bd1c3acca | ||
|
|
70cfc9500e | ||
|
|
61b011cc28 | ||
|
|
391135b1a5 | ||
|
|
12d8d70573 | ||
|
|
04c5aeda2d | ||
|
|
25438be207 | ||
|
|
33f51d76f4 | ||
|
|
e3021909c2 | ||
|
|
61dee1beba | ||
|
|
21e954eec3 | ||
|
|
0b3054a348 | ||
|
|
02f4cb75dd | ||
|
|
3aeb8c6bdb | ||
|
|
8c2b2c7f80 | ||
|
|
745c635a55 | ||
|
|
c7dd31846d | ||
|
|
e87fa4293d | ||
|
|
b269884f8d | ||
|
|
3fed9761a6 | ||
|
|
6ccf196b61 | ||
|
|
a4bd8dc623 | ||
|
|
34f01408c9 | ||
|
|
73074daa07 | ||
|
|
119b80d449 | ||
|
|
60b3103314 | ||
|
|
75ffb9dc84 | ||
|
|
b306d40bf1 | ||
|
|
a27f146338 | ||
|
|
74995358cd | ||
|
|
35da6c32b7 | ||
|
|
701a5c7cb9 | ||
|
|
3c3e7f666b | ||
|
|
89dfa1fd7a | ||
|
|
1da00f0ee3 | ||
|
|
5809a1637f | ||
|
|
e47bea34d5 | ||
|
|
709f17c278 | ||
|
|
3c597dde72 | ||
|
|
0379431812 | ||
|
|
3f9fd85afb | ||
|
|
7b0a235c71 | ||
|
|
55cac23976 | ||
|
|
22a16a3e33 | ||
|
|
db555d12ea | ||
|
|
b9f1390405 | ||
|
|
f2d0aee656 | ||
|
|
2a47727641 | ||
|
|
ccb7f63b8a | ||
|
|
1f9bb6a1c4 | ||
|
|
21b5d2cac5 | ||
|
|
56eeeebed1 | ||
|
|
54627f6807 | ||
|
|
5754d36fdd | ||
|
|
3d14d362a8 | ||
|
|
472e027463 | ||
|
|
b297510d2b | ||
|
|
4932d25540 | ||
|
|
b6c3b743f0 | ||
|
|
1b4edd0e37 | ||
|
|
dcb00b4fe8 | ||
|
|
b33b688373 | ||
|
|
4b97b15c0c | ||
|
|
93c0774036 | ||
|
|
645885d72d | ||
|
|
b5af5f66fb | ||
|
|
fb04f8900a | ||
|
|
3396dce2bb | ||
|
|
3291bd2a4a | ||
|
|
121f01c06f | ||
|
|
6cac2d57ba | ||
|
|
c04b43e047 | ||
|
|
ff20732dd7 | ||
|
|
81af8f296e | ||
|
|
830d1fb42b | ||
|
|
e19cb48d3d | ||
|
|
f755580b11 | ||
|
|
81955005b9 | ||
|
|
62a871773b | ||
|
|
5e52e7f19e | ||
|
|
4c66a6a642 | ||
|
|
9e1deecf13 | ||
|
|
1ce93ccceb | ||
|
|
4b04f8bec1 | ||
|
|
5528bc7b2d | ||
|
|
912f3b19f7 | ||
|
|
9e5e85780b | ||
|
|
10aa3b3ae3 | ||
|
|
bcf7b3f95b | ||
|
|
07f1c784a4 | ||
|
|
465994cff9 | ||
|
|
697ad6cbda | ||
|
|
a840671015 | ||
|
|
7f0ab8308d | ||
|
|
270b9fde04 | ||
|
|
993c9899cb | ||
|
|
c8246e95f1 | ||
|
|
f08de1ed4c | ||
|
|
90f2e0dbb9 | ||
|
|
80a3bd8951 | ||
|
|
b0aec3cbe2 | ||
|
|
5f5e0634dd | ||
|
|
049e605016 | ||
|
|
4687c3e140 | ||
|
|
6d74e223be | ||
|
|
221427a6b4 | ||
|
|
3bf892128d | ||
|
|
abd7f939f2 | ||
|
|
299e9918b9 | ||
|
|
eea83ff613 | ||
|
|
9eceab667c | ||
|
|
026e7649d5 | ||
|
|
c807da7664 | ||
|
|
dde5db621d | ||
|
|
6b95cb4ee0 | ||
|
|
a5f69ef716 | ||
|
|
accccb5f39 | ||
|
|
f8ddccd7d0 | ||
|
|
e06e882962 | ||
|
|
c3f74ca4f1 | ||
|
|
532464f7ae | ||
|
|
570fb013e2 | ||
|
|
71ace9d8d0 | ||
|
|
1cf0326183 | ||
|
|
5b9ebd19d5 | ||
|
|
6ce869b3fb | ||
|
|
06b50ecb98 | ||
|
|
0bc7719572 | ||
|
|
9028f79a27 | ||
|
|
a3e1693a75 | ||
|
|
060b3e23c1 | ||
|
|
612c238157 | ||
|
|
8adbc75811 | ||
|
|
7485e5482c | ||
|
|
659a5436a5 | ||
|
|
c6d7a27848 | ||
|
|
094b198d5d | ||
|
|
22b97a3b54 | ||
|
|
a4f7a5e248 | ||
|
|
45d8cf163e | ||
|
|
d46daa1d7c | ||
|
|
4906cf1aff | ||
|
|
f74fae58e3 | ||
|
|
1602e0e823 | ||
|
|
202ebf06ff | ||
|
|
3e3b71724d | ||
|
|
893fb98522 | ||
|
|
e267226438 | ||
|
|
62626b712b | ||
|
|
7bdf14b210 | ||
|
|
87420e6504 | ||
|
|
c73a3ec356 | ||
|
|
2e23e6a2dc | ||
|
|
5b3ef78101 | ||
|
|
9b262d56a5 | ||
|
|
453b43992d | ||
|
|
a5e3617015 | ||
|
|
c4ad6d1ee6 | ||
|
|
f9cde1b46d | ||
|
|
03bc897b39 | ||
|
|
83fd84745d | ||
|
|
e977967eb5 | ||
|
|
15b00cb3ca | ||
|
|
18e5f72a84 | ||
|
|
47682de0f0 | ||
|
|
b4ea43cbd0 | ||
|
|
08341286a3 | ||
|
|
4c3b0b9a74 | ||
|
|
d250e9e9cc | ||
|
|
75be5eed62 | ||
|
|
e2f86678a4 | ||
|
|
fe7d5dfd19 | ||
|
|
965034e16e | ||
|
|
44398d044f | ||
|
|
3feb874b1e | ||
|
|
f7183e6918 | ||
|
|
707cd2d734 | ||
|
|
c11c3ed2f2 | ||
|
|
5fd0972b5d | ||
|
|
70cb195e6f | ||
|
|
c219adffd5 | ||
|
|
cd6dd5abfd | ||
|
|
29ece0e6ba | ||
|
|
45bad556ab | ||
|
|
30cf63ec92 | ||
|
|
969c2e528d | ||
|
|
bb2bf7ce57 | ||
|
|
2969e156c7 | ||
|
|
b08995cbcc | ||
|
|
47f71f9193 | ||
|
|
fec2eaef7e | ||
|
|
56eb474bf3 | ||
|
|
62b2ab29cd | ||
|
|
a35693554c | ||
|
|
f7427259ee | ||
|
|
e02ab76edf | ||
|
|
9f46c306e5 | ||
|
|
b5c9d779bd | ||
|
|
d2cb1f321e | ||
|
|
8f871a8218 | ||
|
|
4ec7514d10 | ||
|
|
1c7e4c4203 | ||
|
|
7d39fe1c56 | ||
|
|
afa26c37f1 | ||
|
|
2f658ba925 | ||
|
|
0ab810e4cb | ||
|
|
37d086b670 | ||
|
|
5e7f5f390a | ||
|
|
f4cd0bdf29 | ||
|
|
723ea53585 | ||
|
|
93f644fae2 | ||
|
|
82951a469b | ||
|
|
d2d5f649d3 | ||
|
|
5c7526a741 | ||
|
|
17ea48c543 | ||
|
|
55ed202957 | ||
|
|
d5df5505f9 | ||
|
|
dc7f4b4be0 | ||
|
|
406a18067d | ||
|
|
3ae2ebe5ea | ||
|
|
a23dc6b753 | ||
|
|
5f1d3fd775 | ||
|
|
9d4e06e8a8 | ||
|
|
6bc61ec1a1 | ||
|
|
c62f93f930 | ||
|
|
213ae1430e | ||
|
|
ee5d738827 | ||
|
|
eab9bbf04f | ||
|
|
4ed51536bb | ||
|
|
b32a60585b | ||
|
|
66a6568fe7 | ||
|
|
fe32146adc | ||
|
|
69feac3a01 | ||
|
|
05d95acfc3 | ||
|
|
22674bc536 | ||
|
|
23c5ebb00f | ||
|
|
c14869f008 | ||
|
|
c1427d6558 | ||
|
|
2a46e13d33 | ||
|
|
b26e577244 | ||
|
|
9f8710b631 | ||
|
|
aba8cb1b08 | ||
|
|
92cd80226c | ||
|
|
10d335ccb1 | ||
|
|
4eeb8c4bd2 | ||
|
|
4d146bacb1 | ||
|
|
7de4caffca | ||
|
|
8db0cb9fa5 | ||
|
|
c30b3d3c48 | ||
|
|
52db4fbf8c | ||
|
|
5cd8f2c52c | ||
|
|
5a1aa44393 | ||
|
|
432696d6eb | ||
|
|
3df7bd98f4 | ||
|
|
1f870911c9 | ||
|
|
4bb9392753 | ||
|
|
fdffacfb40 | ||
|
|
a64afe6162 | ||
|
|
15b86a5f7a | ||
|
|
9b78fb67cf | ||
|
|
4817b96bac | ||
|
|
6985802eb3 | ||
|
|
aad0ce162d | ||
|
|
f582b73035 | ||
|
|
e795f41bd2 | ||
|
|
5d541232ef | ||
|
|
07513ba928 | ||
|
|
aded80c101 | ||
|
|
5d893947ea | ||
|
|
535cf28220 | ||
|
|
dbe5328c33 | ||
|
|
6e15a4da0e | ||
|
|
fc51f0ef6c | ||
|
|
1f2c8df5fa | ||
|
|
bea40a7a92 | ||
|
|
f679590bef | ||
|
|
bd61131f5c | ||
|
|
ff25361896 | ||
|
|
08dcc7e107 | ||
|
|
b027b5cf0d | ||
|
|
0f2a2ee11e | ||
|
|
a93229b14d | ||
|
|
2d3f6b80c1 | ||
|
|
9503ea3040 | ||
|
|
08539a156e | ||
|
|
b183b091ee | ||
|
|
c39415da44 | ||
|
|
2c461f6474 | ||
|
|
e213964793 | ||
|
|
dd753d3b78 | ||
|
|
45c0d4c2ea | ||
|
|
4f89f90dab | ||
|
|
0270e48a01 | ||
|
|
a278d8f018 | ||
|
|
d4a180c413 | ||
|
|
28a8c05513 | ||
|
|
879b3d76bd | ||
|
|
138692183b | ||
|
|
95f3e2f79f | ||
|
|
dec9950649 | ||
|
|
2f6b69b580 | ||
|
|
ff1fd97924 | ||
|
|
87e60dccf0 | ||
|
|
8ff977dc65 | ||
|
|
fbfa12c733 | ||
|
|
6a45d25777 | ||
|
|
2b5d596e10 | ||
|
|
e2a71d3c2c | ||
|
|
807e0b479d | ||
|
|
dfa63839bb | ||
|
|
0490cb2920 | ||
|
|
2d0ad73af8 | ||
|
|
5a81fcd42e | ||
|
|
6446e0004c | ||
|
|
edf5f4947e | ||
|
|
b674163a40 | ||
|
|
9f2badb3e9 | ||
|
|
0610e20a3c | ||
|
|
bedc005d67 | ||
|
|
a8a46257ae | ||
|
|
b41afe79b4 | ||
|
|
448ed36cd2 | ||
|
|
c4d19cd1fa | ||
|
|
495ca64c46 | ||
|
|
0f2cf552e9 | ||
|
|
f6a1f16146 | ||
|
|
db6bc0ba02 | ||
|
|
e4bb6c91e7 | ||
|
|
561a02c35f | ||
|
|
51e80484e2 | ||
|
|
79fa4723ab | ||
|
|
a3c8c0b492 | ||
|
|
2f389f1d51 | ||
|
|
85e5dffad5 | ||
|
|
fa63288f52 | ||
|
|
4ea8be8e0b | ||
|
|
48c501a7a2 | ||
|
|
63c2b2bc64 | ||
|
|
639be2ff09 | ||
|
|
8b1b3ea402 | ||
|
|
9c3040b704 | ||
|
|
e7291f57ba | ||
|
|
3f6eceac77 | ||
|
|
ba7a454f92 | ||
|
|
3092d74a08 | ||
|
|
ff8e0c9751 | ||
|
|
3e518e3cf9 | ||
|
|
7667e16732 | ||
|
|
e110042275 | ||
|
|
06677b0545 | ||
|
|
20d105ba4e | ||
|
|
e77f4f61aa | ||
|
|
9de729e825 | ||
|
|
c39c2e3599 | ||
|
|
ecfa212189 | ||
|
|
97fd126a7f | ||
|
|
844c756940 | ||
|
|
a90bf75395 | ||
|
|
79bb0da153 | ||
|
|
c88b1f6a15 | ||
|
|
b224d58a36 | ||
|
|
7d348b5eae | ||
|
|
02ac3edebf | ||
|
|
4bad3e0f4f | ||
|
|
8147ef554a | ||
|
|
785c4fb5a0 | ||
|
|
13b2dc8d31 | ||
|
|
a62923ff97 | ||
|
|
dd6be80fca | ||
|
|
8c077f0f65 | ||
|
|
2c4c4cc93e | ||
|
|
1ab3b183a8 | ||
|
|
e6a53bd852 | ||
|
|
b983b3fcdc | ||
|
|
89cac4071e | ||
|
|
506ea8aa52 | ||
|
|
b965fcf32d | ||
|
|
126f6c2d88 | ||
|
|
3dc456572b | ||
|
|
0f26072ad0 | ||
|
|
dc9cec2611 | ||
|
|
c9aeae757b | ||
|
|
094c2682bd | ||
|
|
066ee52615 | ||
|
|
ee1c9b284a | ||
|
|
d9fba94983 | ||
|
|
e02bedcf82 | ||
|
|
1552470413 | ||
|
|
e2f3c2259b | ||
|
|
249bd99656 | ||
|
|
b36196286a | ||
|
|
b21780b738 | ||
|
|
207ec81821 | ||
|
|
d61aaf393a | ||
|
|
19c44c9b62 | ||
|
|
4deabf5e01 | ||
|
|
1a6194e9f0 | ||
|
|
156a0b13d9 | ||
|
|
61a7f7a567 | ||
|
|
dbcb9df22b | ||
|
|
e2ad1190ac | ||
|
|
c0f9058f15 | ||
|
|
12859e575a | ||
|
|
3f765c356a | ||
|
|
fd8b540a66 | ||
|
|
29267593c2 | ||
|
|
1e74805aa4 | ||
|
|
12685aa54a | ||
|
|
04f07f4c15 | ||
|
|
df386a3b3f | ||
|
|
13c49ad865 | ||
|
|
7c01bba4f4 | ||
|
|
950d1199c2 | ||
|
|
38d1381c02 | ||
|
|
98f15d001f | ||
|
|
a379530d41 | ||
|
|
e19b67cb79 | ||
|
|
e883a559ca | ||
|
|
713f6f32e1 | ||
|
|
872b36c11d | ||
|
|
f761c25dcd | ||
|
|
38e1991f82 | ||
|
|
13d3b3a3ce | ||
|
|
0c2a13b468 | ||
|
|
4e7408dc25 | ||
|
|
76dac9c09c | ||
|
|
9339058fc3 | ||
|
|
8e3e06a6e9 | ||
|
|
fd80d784f4 | ||
|
|
ae4f6309e8 | ||
|
|
c466537a26 | ||
|
|
001c915c21 | ||
|
|
91a7102f11 | ||
|
|
a451e90374 | ||
|
|
c6a6788694 | ||
|
|
522df2a355 | ||
|
|
863de88671 | ||
|
|
cb57a1ca1f | ||
|
|
32098e5a13 | ||
|
|
210d673ef0 | ||
|
|
0b5b6113ee | ||
|
|
d5c98165ea | ||
|
|
b8d22bc572 | ||
|
|
69808ba523 | ||
|
|
aabfba9599 | ||
|
|
135620b14a | ||
|
|
78a4974de9 |
10
.gitignore
vendored
@@ -1,6 +1,10 @@
|
||||
raw
|
||||
presentation
|
||||
test.coffee
|
||||
test*.coffee
|
||||
test.litcoffee
|
||||
test*.litcoffee
|
||||
test/*.js
|
||||
parser.output
|
||||
test/fixtures/underscore
|
||||
examples/beautiful_code/parse.coffee
|
||||
*.gem
|
||||
/node_modules
|
||||
npm-debug.log*
|
||||
|
||||
9
CONTRIBUTING.md
Normal file
@@ -0,0 +1,9 @@
|
||||
## How to contribute to CoffeeScript
|
||||
|
||||
* Before you open a ticket or send a pull request, [search](https://github.com/jashkenas/coffeescript/issues) for previous discussions about the same feature or issue. Add to the earlier ticket if you find one.
|
||||
|
||||
* Before sending a pull request for a feature, be sure to have [tests](https://github.com/jashkenas/coffeescript/tree/master/test).
|
||||
|
||||
* Use the same coding style as the rest of the [codebase](https://github.com/jashkenas/coffeescript/tree/master/src). If you’re just getting started with CoffeeScript, there’s a nice [style guide](https://github.com/polarmobile/coffeescript-style-guide).
|
||||
|
||||
* In your pull request, do not add documentation to `index.html` or re-build the minified `coffeescript.js` file. We’ll do those things before cutting a new release.
|
||||
440
Cakefile
Normal file
@@ -0,0 +1,440 @@
|
||||
fs = require 'fs'
|
||||
path = require 'path'
|
||||
_ = require 'underscore'
|
||||
{ spawn, exec, execSync } = require 'child_process'
|
||||
CoffeeScript = require './lib/coffeescript'
|
||||
helpers = require './lib/coffeescript/helpers'
|
||||
|
||||
# ANSI Terminal Colors.
|
||||
bold = red = green = reset = ''
|
||||
unless process.env.NODE_DISABLE_COLORS
|
||||
bold = '\x1B[0;1m'
|
||||
red = '\x1B[0;31m'
|
||||
green = '\x1B[0;32m'
|
||||
reset = '\x1B[0m'
|
||||
|
||||
# Built file header.
|
||||
header = """
|
||||
/**
|
||||
* CoffeeScript Compiler v#{CoffeeScript.VERSION}
|
||||
* http://coffeescript.org
|
||||
*
|
||||
* Copyright 2011, Jeremy Ashkenas
|
||||
* Released under the MIT License
|
||||
*/
|
||||
"""
|
||||
|
||||
# Used in folder names like `docs/v1`.
|
||||
majorVersion = parseInt CoffeeScript.VERSION.split('.')[0], 10
|
||||
|
||||
|
||||
# Log a message with a color.
|
||||
log = (message, color, explanation) ->
|
||||
console.log color + message + reset + ' ' + (explanation or '')
|
||||
|
||||
|
||||
spawnNodeProcess = (args, output = 'stderr', callback) ->
|
||||
relayOutput = (buffer) -> console.log buffer.toString()
|
||||
proc = spawn 'node', args
|
||||
proc.stdout.on 'data', relayOutput if output is 'both' or output is 'stdout'
|
||||
proc.stderr.on 'data', relayOutput if output is 'both' or output is 'stderr'
|
||||
proc.on 'exit', (status) -> callback(status) if typeof callback is 'function'
|
||||
|
||||
# Run a CoffeeScript through our node/coffee interpreter.
|
||||
run = (args, callback) ->
|
||||
spawnNodeProcess ['bin/coffee'].concat(args), 'stderr', (status) ->
|
||||
process.exit(1) if status isnt 0
|
||||
callback() if typeof callback is 'function'
|
||||
|
||||
|
||||
# Build the CoffeeScript language from source.
|
||||
buildParser = ->
|
||||
helpers.extend global, require 'util'
|
||||
require 'jison'
|
||||
parser = require('./lib/coffeescript/grammar').parser.generate()
|
||||
# Patch Jison’s output, until https://github.com/zaach/jison/pull/339 is accepted,
|
||||
# to ensure that require('fs') is only called where it exists.
|
||||
parser = parser.replace "var source = require('fs')", """
|
||||
var source = '';
|
||||
var fs = require('fs');
|
||||
if (typeof fs !== 'undefined' && fs !== null)
|
||||
source = fs"""
|
||||
fs.writeFileSync 'lib/coffeescript/parser.js', parser
|
||||
|
||||
buildExceptParser = (callback) ->
|
||||
files = fs.readdirSync 'src'
|
||||
files = ('src/' + file for file in files when file.match(/\.(lit)?coffee$/))
|
||||
run ['-c', '-o', 'lib/coffeescript'].concat(files), callback
|
||||
|
||||
build = (callback) ->
|
||||
buildParser()
|
||||
buildExceptParser callback
|
||||
|
||||
testBuiltCode = (watch = no) ->
|
||||
csPath = './lib/coffeescript'
|
||||
csDir = path.dirname require.resolve csPath
|
||||
|
||||
for mod of require.cache when csDir is mod[0 ... csDir.length]
|
||||
delete require.cache[mod]
|
||||
|
||||
testResults = runTests require csPath
|
||||
unless watch
|
||||
process.exit 1 unless testResults
|
||||
|
||||
buildAndTest = (includingParser = yes, harmony = no) ->
|
||||
process.stdout.write '\x1Bc' # Clear terminal screen.
|
||||
execSync 'git checkout lib/*', stdio: [0,1,2] # Reset the generated compiler.
|
||||
|
||||
buildArgs = ['bin/cake']
|
||||
buildArgs.push if includingParser then 'build' else 'build:except-parser'
|
||||
log "building#{if includingParser then ', including parser' else ''}...", green
|
||||
spawnNodeProcess buildArgs, 'both', ->
|
||||
log 'testing...', green
|
||||
testArgs = if harmony then ['--harmony'] else []
|
||||
testArgs = testArgs.concat ['bin/cake', 'test']
|
||||
spawnNodeProcess testArgs, 'both'
|
||||
|
||||
watchAndBuildAndTest = (harmony = no) ->
|
||||
buildAndTest yes, harmony
|
||||
fs.watch 'src/', interval: 200, (eventType, filename) ->
|
||||
if eventType is 'change'
|
||||
log "src/#{filename} changed, rebuilding..."
|
||||
buildAndTest (filename is 'grammar.coffee'), harmony
|
||||
fs.watch 'test/', {interval: 200, recursive: yes}, (eventType, filename) ->
|
||||
if eventType is 'change'
|
||||
log "test/#{filename} changed, rebuilding..."
|
||||
buildAndTest no, harmony
|
||||
|
||||
|
||||
task 'build', 'build the CoffeeScript compiler from source', build
|
||||
|
||||
task 'build:parser', 'build the Jison parser only', buildParser
|
||||
|
||||
task 'build:except-parser', 'build the CoffeeScript compiler, except for the Jison parser', buildExceptParser
|
||||
|
||||
task 'build:full', 'build the CoffeeScript compiler from source twice, and run the tests', ->
|
||||
build ->
|
||||
build testBuiltCode
|
||||
|
||||
task 'build:browser', 'build the merged script for inclusion in the browser', ->
|
||||
code = """
|
||||
require['../../package.json'] = (function() {
|
||||
return #{fs.readFileSync "./package.json"};
|
||||
})();
|
||||
"""
|
||||
for {name, src} in [{name: 'markdown-it', src: 'dist/markdown-it.min.js'}]
|
||||
code += """
|
||||
require['#{name}'] = (function() {
|
||||
var exports = {}, module = {exports: exports};
|
||||
#{fs.readFileSync "node_modules/#{name}/#{src}"}
|
||||
return module.exports;
|
||||
})();
|
||||
"""
|
||||
for name in ['helpers', 'rewriter', 'lexer', 'parser', 'scope', 'nodes', 'sourcemap', 'coffeescript', 'browser']
|
||||
code += """
|
||||
require['./#{name}'] = (function() {
|
||||
var exports = {}, module = {exports: exports};
|
||||
#{fs.readFileSync "lib/coffeescript/#{name}.js"}
|
||||
return module.exports;
|
||||
})();
|
||||
"""
|
||||
code = """
|
||||
(function(root) {
|
||||
var CoffeeScript = function() {
|
||||
function require(path){ return require[path]; }
|
||||
#{code}
|
||||
return require['./coffeescript'];
|
||||
}();
|
||||
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
define(function() { return CoffeeScript; });
|
||||
} else {
|
||||
root.CoffeeScript = CoffeeScript;
|
||||
}
|
||||
}(this));
|
||||
"""
|
||||
unless process.env.MINIFY is 'false'
|
||||
{compiledCode: code} = require('google-closure-compiler-js').compile
|
||||
jsCode: [
|
||||
src: code
|
||||
languageOut: if majorVersion is 1 then 'ES5' else 'ES6'
|
||||
]
|
||||
outputFolder = "docs/v#{majorVersion}/browser-compiler"
|
||||
fs.mkdirSync outputFolder unless fs.existsSync outputFolder
|
||||
fs.writeFileSync "#{outputFolder}/coffeescript.js", header + '\n' + code
|
||||
console.log "built ... running browser tests:"
|
||||
invoke 'test:browser'
|
||||
|
||||
task 'build:watch', 'watch and continually rebuild the CoffeeScript compiler, running tests on each build', ->
|
||||
watchAndBuildAndTest()
|
||||
|
||||
task 'build:watch:harmony', 'watch and continually rebuild the CoffeeScript compiler, running harmony tests on each build', ->
|
||||
watchAndBuildAndTest yes
|
||||
|
||||
|
||||
buildDocs = (watch = no) ->
|
||||
# Constants
|
||||
indexFile = 'documentation/index.html'
|
||||
versionedSourceFolder = "documentation/v#{majorVersion}"
|
||||
sectionsSourceFolder = 'documentation/sections'
|
||||
examplesSourceFolder = 'documentation/examples'
|
||||
outputFolder = "docs/v#{majorVersion}"
|
||||
|
||||
# Helpers
|
||||
releaseHeader = (date, version, prevVersion) ->
|
||||
monthNames = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December']
|
||||
|
||||
formatDate = (date) ->
|
||||
date.replace /^(\d\d\d\d)-(\d\d)-(\d\d)$/, (match, $1, $2, $3) ->
|
||||
"#{monthNames[$2 - 1]} #{+$3}, #{$1}"
|
||||
|
||||
"""
|
||||
<div class="anchor" id="#{version}"></div>
|
||||
<h2 class="header">
|
||||
#{prevVersion and "<a href=\"https://github.com/jashkenas/coffeescript/compare/#{prevVersion}...#{version}\">#{version}</a>" or version}
|
||||
<span class="timestamp"> — <time datetime="#{date}">#{formatDate date}</time></span>
|
||||
</h2>
|
||||
"""
|
||||
|
||||
codeFor = require "./documentation/v#{majorVersion}/code.coffee"
|
||||
|
||||
htmlFor = ->
|
||||
hljs = require 'highlight.js'
|
||||
hljs.configure classPrefix: ''
|
||||
markdownRenderer = require('markdown-it')
|
||||
html: yes
|
||||
typographer: yes
|
||||
highlight: (str, lang) ->
|
||||
# From https://github.com/markdown-it/markdown-it#syntax-highlighting
|
||||
if lang and hljs.getLanguage(lang)
|
||||
try
|
||||
return hljs.highlight(lang, str).value
|
||||
catch ex
|
||||
return '' # No syntax highlighting
|
||||
|
||||
|
||||
# Add some custom overrides to Markdown-It’s rendering, per
|
||||
# https://github.com/markdown-it/markdown-it/blob/master/docs/architecture.md#renderer
|
||||
defaultFence = markdownRenderer.renderer.rules.fence
|
||||
markdownRenderer.renderer.rules.fence = (tokens, idx, options, env, slf) ->
|
||||
code = tokens[idx].content
|
||||
if code.indexOf('codeFor(') is 0 or code.indexOf('releaseHeader(') is 0
|
||||
"<%= #{code} %>"
|
||||
else
|
||||
"<blockquote class=\"uneditable-code-block\">#{defaultFence.apply @, arguments}</blockquote>"
|
||||
|
||||
(file, bookmark) ->
|
||||
md = fs.readFileSync "#{sectionsSourceFolder}/#{file}.md", 'utf-8'
|
||||
md = md.replace /<%= releaseHeader %>/g, releaseHeader
|
||||
md = md.replace /<%= majorVersion %>/g, majorVersion
|
||||
md = md.replace /<%= fullVersion %>/g, CoffeeScript.VERSION
|
||||
html = markdownRenderer.render md
|
||||
html = _.template(html)
|
||||
codeFor: codeFor()
|
||||
releaseHeader: releaseHeader
|
||||
|
||||
include = ->
|
||||
(file) ->
|
||||
file = "#{versionedSourceFolder}/#{file}" if file.indexOf('/') is -1
|
||||
output = fs.readFileSync file, 'utf-8'
|
||||
if /\.html$/.test(file)
|
||||
render = _.template output
|
||||
output = render
|
||||
releaseHeader: releaseHeader
|
||||
majorVersion: majorVersion
|
||||
fullVersion: CoffeeScript.VERSION
|
||||
htmlFor: htmlFor()
|
||||
codeFor: codeFor()
|
||||
include: include()
|
||||
output
|
||||
|
||||
# Task
|
||||
do renderIndex = ->
|
||||
render = _.template fs.readFileSync(indexFile, 'utf-8')
|
||||
output = render
|
||||
include: include()
|
||||
fs.writeFileSync "#{outputFolder}/index.html", output
|
||||
log 'compiled', green, "#{indexFile} → #{outputFolder}/index.html"
|
||||
try
|
||||
fs.symlinkSync "v#{majorVersion}/index.html", 'docs/index.html'
|
||||
catch exception
|
||||
|
||||
if watch
|
||||
for target in [indexFile, versionedSourceFolder, examplesSourceFolder, sectionsSourceFolder]
|
||||
fs.watch target, interval: 200, renderIndex
|
||||
log 'watching...', green
|
||||
|
||||
task 'doc:site', 'build the documentation for the website', ->
|
||||
buildDocs()
|
||||
|
||||
task 'doc:site:watch', 'watch and continually rebuild the documentation for the website', ->
|
||||
buildDocs yes
|
||||
|
||||
|
||||
buildDocTests = (watch = no) ->
|
||||
# Constants
|
||||
testFile = 'documentation/test.html'
|
||||
testsSourceFolder = 'test'
|
||||
outputFolder = "docs/v#{majorVersion}"
|
||||
|
||||
# Included in test.html
|
||||
testHelpers = fs.readFileSync('test/support/helpers.coffee', 'utf-8').replace /exports\./g, '@'
|
||||
|
||||
# Helpers
|
||||
testsInScriptBlocks = ->
|
||||
output = ''
|
||||
for filename in fs.readdirSync testsSourceFolder
|
||||
if filename.indexOf('.coffee') isnt -1
|
||||
type = 'coffeescript'
|
||||
else if filename.indexOf('.litcoffee') isnt -1
|
||||
type = 'literate-coffeescript'
|
||||
else
|
||||
continue
|
||||
|
||||
# Set the type to text/x-coffeescript or text/x-literate-coffeescript
|
||||
# to prevent the browser compiler from automatically running the script
|
||||
output += """
|
||||
<script type="text/x-#{type}" class="test" id="#{filename.split('.')[0]}">
|
||||
#{fs.readFileSync "test/#{filename}", 'utf-8'}
|
||||
</script>\n
|
||||
"""
|
||||
output
|
||||
|
||||
# Task
|
||||
do renderTest = ->
|
||||
render = _.template fs.readFileSync(testFile, 'utf-8')
|
||||
output = render
|
||||
testHelpers: testHelpers
|
||||
tests: testsInScriptBlocks()
|
||||
fs.writeFileSync "#{outputFolder}/test.html", output
|
||||
log 'compiled', green, "#{testFile} → #{outputFolder}/test.html"
|
||||
|
||||
if watch
|
||||
for target in [testFile, testsSourceFolder]
|
||||
fs.watch target, interval: 200, renderTest
|
||||
log 'watching...', green
|
||||
|
||||
task 'doc:test', 'build the browser-based tests', ->
|
||||
buildDocTests()
|
||||
|
||||
task 'doc:test:watch', 'watch and continually rebuild the browser-based tests', ->
|
||||
buildDocTests yes
|
||||
|
||||
|
||||
buildAnnotatedSource = (watch = no) ->
|
||||
do generateAnnotatedSource = ->
|
||||
exec "node_modules/docco/bin/docco src/*.*coffee --output docs/v#{majorVersion}/annotated-source", (err) -> throw err if err
|
||||
log 'generated', green, "annotated source in docs/v#{majorVersion}/annotated-source/"
|
||||
|
||||
if watch
|
||||
fs.watch 'src/', interval: 200, generateAnnotatedSource
|
||||
log 'watching...', green
|
||||
|
||||
task 'doc:source', 'build the annotated source documentation', ->
|
||||
buildAnnotatedSource()
|
||||
|
||||
task 'doc:source:watch', 'watch and continually rebuild the annotated source documentation', ->
|
||||
buildAnnotatedSource yes
|
||||
|
||||
|
||||
task 'release', 'build and test the CoffeeScript source, and build the documentation', ->
|
||||
invoke 'build:full'
|
||||
invoke 'build:browser'
|
||||
invoke 'doc:site'
|
||||
invoke 'doc:test'
|
||||
invoke 'doc:source'
|
||||
|
||||
task 'bench', 'quick benchmark of compilation time', ->
|
||||
{Rewriter} = require './lib/coffeescript/rewriter'
|
||||
sources = ['coffeescript', 'grammar', 'helpers', 'lexer', 'nodes', 'rewriter']
|
||||
coffee = sources.map((name) -> fs.readFileSync "src/#{name}.coffee").join '\n'
|
||||
litcoffee = fs.readFileSync("src/scope.litcoffee").toString()
|
||||
fmt = (ms) -> " #{bold}#{ " #{ms}".slice -4 }#{reset} ms"
|
||||
total = 0
|
||||
now = Date.now()
|
||||
time = -> total += ms = -(now - now = Date.now()); fmt ms
|
||||
tokens = CoffeeScript.tokens coffee, rewrite: no
|
||||
littokens = CoffeeScript.tokens litcoffee, rewrite: no, literate: yes
|
||||
tokens = tokens.concat(littokens)
|
||||
console.log "Lex #{time()} (#{tokens.length} tokens)"
|
||||
tokens = new Rewriter().rewrite tokens
|
||||
console.log "Rewrite#{time()} (#{tokens.length} tokens)"
|
||||
nodes = CoffeeScript.nodes tokens
|
||||
console.log "Parse #{time()}"
|
||||
js = nodes.compile bare: yes
|
||||
console.log "Compile#{time()} (#{js.length} chars)"
|
||||
console.log "total #{ fmt total }"
|
||||
|
||||
|
||||
# Run the CoffeeScript test suite.
|
||||
runTests = (CoffeeScript) ->
|
||||
CoffeeScript.register()
|
||||
startTime = Date.now()
|
||||
|
||||
# These are attached to `global` so that they’re accessible from within
|
||||
# `test/async.coffee`, which has an async-capable version of
|
||||
# `global.test`.
|
||||
global.currentFile = null
|
||||
global.passedTests = 0
|
||||
global.failures = []
|
||||
|
||||
global[name] = func for name, func of require 'assert'
|
||||
|
||||
# Convenience aliases.
|
||||
global.CoffeeScript = CoffeeScript
|
||||
global.Repl = require './lib/coffeescript/repl'
|
||||
|
||||
# Our test helper function for delimiting different test cases.
|
||||
global.test = (description, fn) ->
|
||||
try
|
||||
fn.test = {description, currentFile}
|
||||
fn.call(fn)
|
||||
++passedTests
|
||||
catch e
|
||||
failures.push
|
||||
filename: currentFile
|
||||
error: e
|
||||
description: description if description?
|
||||
source: fn.toString() if fn.toString?
|
||||
|
||||
helpers.extend global, require './test/support/helpers'
|
||||
|
||||
# When all the tests have run, collect and print errors.
|
||||
# If a stacktrace is available, output the compiled function source.
|
||||
process.on 'exit', ->
|
||||
time = ((Date.now() - startTime) / 1000).toFixed(2)
|
||||
message = "passed #{passedTests} tests in #{time} seconds#{reset}"
|
||||
return log(message, green) unless failures.length
|
||||
log "failed #{failures.length} and #{message}", red
|
||||
for fail in failures
|
||||
{error, filename, description, source} = fail
|
||||
console.log ''
|
||||
log " #{description}", red if description
|
||||
log " #{error.stack}", red
|
||||
console.log " #{source}" if source
|
||||
return
|
||||
|
||||
# Run every test in the `test` folder, recording failures.
|
||||
files = fs.readdirSync 'test'
|
||||
|
||||
for file in files when helpers.isCoffee file
|
||||
literate = helpers.isLiterate file
|
||||
currentFile = filename = path.join 'test', file
|
||||
code = fs.readFileSync filename
|
||||
try
|
||||
CoffeeScript.run code.toString(), {filename, literate}
|
||||
catch error
|
||||
failures.push {filename, error}
|
||||
return !failures.length
|
||||
|
||||
|
||||
task 'test', 'run the CoffeeScript language test suite', ->
|
||||
runTests CoffeeScript
|
||||
|
||||
|
||||
task 'test:browser', 'run the test suite against the merged browser script', ->
|
||||
source = fs.readFileSync "docs/v#{majorVersion}/browser-compiler/coffeescript.js", 'utf-8'
|
||||
result = {}
|
||||
global.testingBrowser = yes
|
||||
(-> eval source).call result
|
||||
runTests result.CoffeeScript
|
||||
4
LICENSE
@@ -1,4 +1,4 @@
|
||||
Copyright (c) 2010 Jeremy Ashkenas
|
||||
Copyright (c) 2009-2017 Jeremy Ashkenas
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
@@ -19,4 +19,4 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
||||
OTHER DEALINGS IN THE SOFTWARE.
|
||||
OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
41
README
@@ -1,41 +0,0 @@
|
||||
=
|
||||
{
|
||||
} } {
|
||||
{ { } }
|
||||
} }{ {
|
||||
{ }{ } } _____ __ __
|
||||
( }{ }{ { ) / ____| / _|/ _|
|
||||
.- { { } { }} -. | | ___ | |_| |_ ___ ___
|
||||
( ( } { } { } } ) | | / _ \| _| _/ _ \/ _ \
|
||||
|`-..________ ..-'| | |___| (_) | | | || __/ __/
|
||||
| | \_____\___/|_| |_| \___|\___|
|
||||
| ;--.
|
||||
| (__ \ _____ _ _
|
||||
| | ) ) / ____| (_) | |
|
||||
| |/ / | (___ ___ _ __ _ _ __ | |_
|
||||
| ( / \___ \ / __| '__| | '_ \| __|
|
||||
| |/ ____) | (__| | | | |_) | |_
|
||||
| | |_____/ \___|_| |_| .__/ \__|
|
||||
`-.._________..-' | |
|
||||
|_|
|
||||
|
||||
|
||||
CoffeeScript is a little language that compiles into JavaScript.
|
||||
|
||||
Install the compiler:
|
||||
gem install coffee-script
|
||||
|
||||
Compile a script:
|
||||
coffee /path/to/script.coffee
|
||||
|
||||
For documentation, usage, and examples, see:
|
||||
http://jashkenas.github.com/coffee-script/
|
||||
|
||||
To suggest a feature or report a bug:
|
||||
http://github.com/jashkenas/coffee-script/issues/
|
||||
|
||||
The source repository:
|
||||
git://github.com/jashkenas/coffee-script.git
|
||||
|
||||
To build CoffeeScript from source, install the "racc" gem and
|
||||
run "rake build:parser". Then bin/coffee will work.
|
||||
57
README.md
Normal file
@@ -0,0 +1,57 @@
|
||||
{
|
||||
} } {
|
||||
{ { } }
|
||||
} }{ {
|
||||
{ }{ } } _____ __ __
|
||||
{ }{ }{ { } / ____| / _|/ _|
|
||||
.- { { } { }} -. | | ___ | |_| |_ ___ ___
|
||||
( { } { } { } } ) | | / _ \| _| _/ _ \/ _ \
|
||||
|`-..________ ..-'| | |___| (_) | | | || __/ __/
|
||||
| | \_____\___/|_| |_| \___|\___|
|
||||
| ;--.
|
||||
| (__ \ _____ _ _
|
||||
| | ) ) / ____| (_) | |
|
||||
| |/ / | (___ ___ _ __ _ _ __ | |_
|
||||
| ( / \___ \ / __| '__| | '_ \| __|
|
||||
| |/ ____) | (__| | | | |_) | |_
|
||||
| | |_____/ \___|_| |_| .__/ \__|
|
||||
`-.._________..-' | |
|
||||
|_|
|
||||
|
||||
CoffeeScript is a little language that compiles into JavaScript.
|
||||
|
||||
## Installation
|
||||
|
||||
If you have the node package manager, npm, installed:
|
||||
|
||||
```shell
|
||||
npm install --global coffeescript
|
||||
```
|
||||
|
||||
Leave off the `--global` if you don’t wish to install globally.
|
||||
|
||||
## Getting Started
|
||||
|
||||
Execute a script:
|
||||
|
||||
```shell
|
||||
coffee /path/to/script.coffee
|
||||
```
|
||||
|
||||
Compile a script:
|
||||
|
||||
```shell
|
||||
coffee -c /path/to/script.coffee
|
||||
```
|
||||
|
||||
For documentation, usage, and examples, see: http://coffeescript.org/
|
||||
|
||||
To suggest a feature or report a bug: http://github.com/jashkenas/coffeescript/issues
|
||||
|
||||
If you’d like to chat, drop by #coffeescript on Freenode IRC.
|
||||
|
||||
The source repository: https://github.com/jashkenas/coffeescript.git
|
||||
|
||||
Changelog: http://coffeescript.org/#changelog
|
||||
|
||||
Our lovely and talented contributors are listed here: http://github.com/jashkenas/coffeescript/contributors
|
||||
78
Rakefile
@@ -1,78 +0,0 @@
|
||||
require 'erb'
|
||||
require 'fileutils'
|
||||
require 'rake/testtask'
|
||||
|
||||
desc "Run all tests"
|
||||
task :test do
|
||||
$LOAD_PATH.unshift(File.expand_path('test'))
|
||||
require 'redgreen' if Gem.available?('redgreen')
|
||||
require 'test/unit'
|
||||
Dir['test/*/**/test_*.rb'].each {|test| require test }
|
||||
end
|
||||
|
||||
namespace :build do
|
||||
|
||||
desc "Recompile the Racc parser (pass -v and -g for verbose debugging)"
|
||||
task :parser, :racc_args do |t, args|
|
||||
sh "racc #{args[:racc_args]} -o lib/coffee_script/parser.rb lib/coffee_script/grammar.y"
|
||||
end
|
||||
|
||||
desc "Compile the Narwhal interface"
|
||||
task :narwhal do
|
||||
sh "bin/coffee src/narwhal/*.coffee -o lib/coffee_script/narwhal"
|
||||
end
|
||||
|
||||
desc "Continually compile the CoffeeScript/Node.js components with --watch"
|
||||
task :node do
|
||||
sh "bin/coffee -w src/*.coffee -o lib/coffee_script/"
|
||||
end
|
||||
|
||||
desc "Compile and install the Ultraviolet syntax highlighter"
|
||||
task :ultraviolet do
|
||||
sh "plist2syntax extras/CoffeeScript.tmbundle/Syntaxes/CoffeeScript.tmLanguage"
|
||||
sh "sudo mv coffeescript.yaml /usr/local/lib/ruby/gems/1.8/gems/ultraviolet-0.10.2/syntax/coffeescript.syntax"
|
||||
end
|
||||
|
||||
desc "Rebuild the Underscore.coffee documentation page"
|
||||
task :underscore do
|
||||
sh "uv -s coffeescript -t idle -h examples/underscore.coffee > documentation/underscore.html"
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
desc "Build the documentation page"
|
||||
task :doc do
|
||||
source = 'documentation/index.html.erb'
|
||||
child = fork { exec "bin/coffee documentation/coffee/*.coffee -o documentation/js -w" }
|
||||
at_exit { Process.kill("INT", child) }
|
||||
Signal.trap("INT") { exit }
|
||||
# `uv -t idle -s coffeescript -h examples/underscore.coffee > documentation/underscore.html`
|
||||
loop do
|
||||
mtime = File.stat(source).mtime
|
||||
if !@mtime || mtime > @mtime
|
||||
rendered = ERB.new(File.read(source)).result(binding)
|
||||
File.open('index.html', 'w+') {|f| f.write(rendered) }
|
||||
end
|
||||
@mtime = mtime
|
||||
sleep 1
|
||||
end
|
||||
end
|
||||
|
||||
namespace :gem do
|
||||
|
||||
desc 'Build and install the coffee-script gem'
|
||||
task :install do
|
||||
verbose = "lib/coffee_script/parser.output"
|
||||
FileUtils.rm(verbose) if File.exists?(verbose)
|
||||
sh "gem build coffee-script.gemspec"
|
||||
sh "sudo gem install #{Dir['*.gem'].join(' ')} --local --no-ri --no-rdoc"
|
||||
end
|
||||
|
||||
desc 'Uninstall the coffee-script gem'
|
||||
task :uninstall do
|
||||
sh "sudo gem uninstall -x coffee-script"
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
task :default => :test
|
||||
7
bin/cake
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env node
|
||||
|
||||
var path = require('path');
|
||||
var fs = require('fs');
|
||||
var lib = path.join(path.dirname(fs.realpathSync(__filename)), '../lib');
|
||||
|
||||
require(lib + '/coffeescript/cake').run();
|
||||
@@ -1,5 +1,7 @@
|
||||
#!/usr/bin/env ruby
|
||||
#!/usr/bin/env node
|
||||
|
||||
require "#{File.dirname(__FILE__)}/../lib/coffee_script/command_line.rb"
|
||||
var path = require('path');
|
||||
var fs = require('fs');
|
||||
var lib = path.join(path.dirname(fs.realpathSync(__filename)), '../lib');
|
||||
|
||||
CoffeeScript::CommandLine.new
|
||||
require(lib + '/coffeescript/command').run();
|
||||
|
||||
19
bower.json
Normal file
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"name": "coffeescript",
|
||||
"main": [
|
||||
"lib/coffeescript/coffeescript.js"
|
||||
],
|
||||
"description": "Unfancy JavaScript",
|
||||
"keywords": [
|
||||
"javascript",
|
||||
"language",
|
||||
"coffeescript",
|
||||
"compiler"
|
||||
],
|
||||
"author": {
|
||||
"name": "Jeremy Ashkenas"
|
||||
},
|
||||
"ignore": [
|
||||
"test"
|
||||
]
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
Gem::Specification.new do |s|
|
||||
s.name = 'coffee-script'
|
||||
s.version = '0.3.2' # Keep version in sync with coffee-script.rb
|
||||
s.date = '2010-2-8'
|
||||
|
||||
s.homepage = "http://jashkenas.github.com/coffee-script/"
|
||||
s.summary = "The CoffeeScript Compiler"
|
||||
s.description = <<-EOS
|
||||
CoffeeScript is a little language that compiles into JavaScript. Think
|
||||
of it as JavaScript's less ostentatious kid brother -- the same genes,
|
||||
roughly the same height, but a different sense of style. Apart from a
|
||||
handful of bonus goodies, statements in CoffeeScript correspond
|
||||
one-to-one with their equivalent in JavaScript, it's just another
|
||||
way of saying it.
|
||||
EOS
|
||||
|
||||
s.authors = ['Jeremy Ashkenas']
|
||||
s.email = 'jashkenas@gmail.com'
|
||||
s.rubyforge_project = 'coffee-script'
|
||||
s.has_rdoc = false
|
||||
|
||||
s.require_paths = ['lib']
|
||||
s.executables = ['coffee']
|
||||
|
||||
s.files = Dir['bin/*', 'examples/*', 'extras/**/*', 'lib/**/*',
|
||||
'coffee-script.gemspec', 'LICENSE', 'README', 'package.json']
|
||||
end
|
||||
1
docs/CNAME
Normal file
@@ -0,0 +1 @@
|
||||
coffeescript.org
|
||||
BIN
docs/android-chrome-192x192.png
Normal file
|
After Width: | Height: | Size: 7.8 KiB |
BIN
docs/android-chrome-512x512.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
docs/apple-touch-icon.png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
9
docs/browserconfig.xml
Normal file
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<browserconfig>
|
||||
<msapplication>
|
||||
<tile>
|
||||
<square150x150logo src="/mstile-150x150.png"/>
|
||||
<TileColor>#da532c</TileColor>
|
||||
</tile>
|
||||
</msapplication>
|
||||
</browserconfig>
|
||||
BIN
docs/favicon-16x16.png
Normal file
|
After Width: | Height: | Size: 987 B |
BIN
docs/favicon-32x32.png
Normal file
|
After Width: | Height: | Size: 1.6 KiB |
BIN
docs/favicon.ico
Normal file
|
After Width: | Height: | Size: 15 KiB |
1
docs/index.html
Symbolic link
@@ -0,0 +1 @@
|
||||
v1/index.html
|
||||
17
docs/manifest.json
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "",
|
||||
"icons": [
|
||||
{
|
||||
"src": "\/android-chrome-192x192.png",
|
||||
"sizes": "192x192",
|
||||
"type": "image\/png"
|
||||
},
|
||||
{
|
||||
"src": "\/android-chrome-512x512.png",
|
||||
"sizes": "512x512",
|
||||
"type": "image\/png"
|
||||
}
|
||||
],
|
||||
"theme_color": "#ffffff",
|
||||
"display": "standalone"
|
||||
}
|
||||
BIN
docs/mstile-150x150.png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
44
docs/safari-pinned-tab.svg
Normal file
@@ -0,0 +1,44 @@
|
||||
<?xml version="1.0" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
|
||||
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
|
||||
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
|
||||
width="916.000000pt" height="916.000000pt" viewBox="0 0 916.000000 916.000000"
|
||||
preserveAspectRatio="xMidYMid meet">
|
||||
<metadata>
|
||||
Created by potrace 1.11, written by Peter Selinger 2001-2013
|
||||
</metadata>
|
||||
<g transform="translate(0.000000,916.000000) scale(0.100000,-0.100000)"
|
||||
fill="#000000" stroke="none">
|
||||
<path d="M5555 8253 c-199 -8 -487 -49 -670 -94 -283 -70 -464 -155 -829 -387
|
||||
-307 -196 -461 -259 -721 -297 -134 -20 -345 -19 -442 1 -160 33 -243 104
|
||||
-243 208 0 59 38 103 118 139 159 72 516 78 707 11 l70 -24 40 28 c94 66 62
|
||||
162 -73 213 -90 34 -196 48 -352 48 -404 1 -684 -104 -767 -286 -22 -48 -25
|
||||
-65 -21 -138 8 -147 86 -267 241 -368 192 -125 402 -184 702 -194 248 -9 474
|
||||
23 699 99 148 50 244 94 565 262 375 197 551 266 806 319 207 43 297 52 535
|
||||
51 194 0 238 -3 319 -22 199 -46 311 -131 311 -235 0 -125 -160 -221 -435
|
||||
-262 -333 -50 -606 26 -685 191 -25 50 -31 52 -128 29 -258 -61 -317 -257
|
||||
-117 -390 157 -104 371 -149 700 -149 539 1 944 133 1084 352 108 171 68 386
|
||||
-105 557 -195 192 -518 305 -959 335 -143 9 -193 10 -350 3z"/>
|
||||
<path d="M1095 7556 c-323 -132 -512 -261 -576 -391 -35 -73 -33 -161 5 -235
|
||||
139 -267 715 -511 1644 -696 1114 -222 2726 -285 4162 -163 584 49 1082 129
|
||||
1590 255 590 146 1001 330 1155 518 135 165 92 351 -120 513 -68 52 -250 153
|
||||
-276 153 -7 0 1 -15 18 -32 74 -77 93 -189 48 -286 -88 -189 -401 -351 -950
|
||||
-491 -589 -149 -1176 -233 -2060 -293 -302 -21 -1490 -17 -1815 5 -988 68
|
||||
-1692 183 -2240 366 -363 122 -575 252 -646 397 -58 118 -25 250 88 357 34 31
|
||||
59 57 57 57 -2 -1 -40 -16 -84 -34z"/>
|
||||
<path d="M554 6215 c42 -244 59 -335 76 -415 53 -243 141 -560 215 -779 19
|
||||
-58 35 -108 35 -112 0 -4 -43 -38 -97 -75 -176 -126 -380 -340 -500 -527 -113
|
||||
-176 -202 -394 -245 -602 -20 -96 -23 -139 -23 -330 0 -198 3 -229 24 -315 47
|
||||
-189 122 -347 237 -500 235 -313 529 -501 879 -560 109 -19 341 -14 475 9 106
|
||||
18 460 129 484 152 6 5 -15 9 -50 9 -158 0 -384 62 -556 152 -224 117 -495
|
||||
354 -622 546 -119 178 -177 338 -216 592 -62 402 38 761 288 1030 l60 65 22
|
||||
-50 c175 -407 322 -695 457 -894 59 -86 238 -340 398 -566 414 -584 421 -593
|
||||
471 -701 97 -210 179 -432 220 -599 19 -80 58 -137 172 -252 180 -182 363
|
||||
-282 727 -398 303 -96 462 -132 770 -177 128 -18 1029 -18 1175 0 304 39 499
|
||||
81 780 169 266 83 422 160 600 294 77 58 207 185 257 251 15 20 35 38 43 41
|
||||
10 2 21 34 33 93 37 180 111 402 199 595 23 50 146 230 360 530 518 724 597
|
||||
846 743 1142 270 549 475 1133 614 1752 45 203 92 447 88 452 -2 2 -22 -19
|
||||
-45 -46 -153 -181 -518 -355 -1007 -479 -1503 -383 -3714 -462 -5485 -196
|
||||
-390 58 -751 129 -988 195 -511 141 -861 305 -1025 482 -46 50 -48 51 -43 22z"/>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.7 KiB |
299
docs/v1/annotated-source/browser.html
Normal file
@@ -0,0 +1,299 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>browser.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>browser.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>This <strong>Browser</strong> compatibility layer extends core CoffeeScript functions
|
||||
to make things work smoothly when compiling code directly in the browser.
|
||||
We add support for loading remote Coffee scripts via <strong>XHR</strong>, and
|
||||
<code>text/coffeescript</code> script tags, source maps via data-URLs, and so on.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>
|
||||
CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffee-script'</span>
|
||||
CoffeeScript.<span class="hljs-built_in">require</span> = <span class="hljs-built_in">require</span>
|
||||
compile = CoffeeScript.compile</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Use standard JavaScript <code>eval</code> to eval code.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript.eval = <span class="hljs-function"><span class="hljs-params">(code, options = {})</span> -></span>
|
||||
options.bare ?= <span class="hljs-literal">on</span>
|
||||
eval compile code, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Running code does not provide access to this scope.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript.run = <span class="hljs-function"><span class="hljs-params">(code, options = {})</span> -></span>
|
||||
options.bare = <span class="hljs-literal">on</span>
|
||||
options.shiftLine = <span class="hljs-literal">on</span>
|
||||
Function(compile code, options)()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>If we’re not in a browser environment, we’re finished with the public API.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> <span class="hljs-built_in">window</span>?</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Include source maps where possible. If we’ve got a base64 encoder, a
|
||||
JSON serializer, and tools for escaping unicode characters, we’re good to go.
|
||||
Ported from <a href="https://developer.mozilla.org/en-US/docs/DOM/window.btoa">https://developer.mozilla.org/en-US/docs/DOM/window.btoa</a></p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> btoa? <span class="hljs-keyword">and</span> JSON?
|
||||
<span class="hljs-function"> <span class="hljs-title">compile</span> = <span class="hljs-params">(code, options = {})</span> -></span>
|
||||
options.inlineMap = <span class="hljs-literal">true</span>
|
||||
CoffeeScript.compile code, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Load a remote script from the current domain via XHR.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript.load = <span class="hljs-function"><span class="hljs-params">(url, callback, options = {}, hold = <span class="hljs-literal">false</span>)</span> -></span>
|
||||
options.sourceFiles = [url]
|
||||
xhr = <span class="hljs-keyword">if</span> <span class="hljs-built_in">window</span>.ActiveXObject
|
||||
<span class="hljs-keyword">new</span> <span class="hljs-built_in">window</span>.ActiveXObject(<span class="hljs-string">'Microsoft.XMLHTTP'</span>)
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-keyword">new</span> <span class="hljs-built_in">window</span>.XMLHttpRequest()
|
||||
xhr.open <span class="hljs-string">'GET'</span>, url, <span class="hljs-literal">true</span>
|
||||
xhr.overrideMimeType <span class="hljs-string">'text/plain'</span> <span class="hljs-keyword">if</span> <span class="hljs-string">'overrideMimeType'</span> <span class="hljs-keyword">of</span> xhr
|
||||
xhr.onreadystatechange = <span class="hljs-function">-></span>
|
||||
<span class="hljs-keyword">if</span> xhr.readyState <span class="hljs-keyword">is</span> <span class="hljs-number">4</span>
|
||||
<span class="hljs-keyword">if</span> xhr.status <span class="hljs-keyword">in</span> [<span class="hljs-number">0</span>, <span class="hljs-number">200</span>]
|
||||
param = [xhr.responseText, options]
|
||||
CoffeeScript.run param... <span class="hljs-keyword">unless</span> hold
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"Could not load <span class="hljs-subst">#{url}</span>"</span>
|
||||
callback param <span class="hljs-keyword">if</span> callback
|
||||
xhr.send <span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Activate CoffeeScript in the browser by having it compile and evaluate
|
||||
all script tags with a content-type of <code>text/coffeescript</code>.
|
||||
This happens on page load.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">runScripts</span> = -></span>
|
||||
scripts = <span class="hljs-built_in">window</span>.<span class="hljs-built_in">document</span>.getElementsByTagName <span class="hljs-string">'script'</span>
|
||||
coffeetypes = [<span class="hljs-string">'text/coffeescript'</span>, <span class="hljs-string">'text/literate-coffeescript'</span>]
|
||||
coffees = (s <span class="hljs-keyword">for</span> s <span class="hljs-keyword">in</span> scripts <span class="hljs-keyword">when</span> s.type <span class="hljs-keyword">in</span> coffeetypes)
|
||||
index = <span class="hljs-number">0</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">execute</span> = -></span>
|
||||
param = coffees[index]
|
||||
<span class="hljs-keyword">if</span> param <span class="hljs-keyword">instanceof</span> Array
|
||||
CoffeeScript.run param...
|
||||
index++
|
||||
execute()
|
||||
|
||||
<span class="hljs-keyword">for</span> script, i <span class="hljs-keyword">in</span> coffees
|
||||
<span class="hljs-keyword">do</span> (script, i) ->
|
||||
options = literate: script.type <span class="hljs-keyword">is</span> coffeetypes[<span class="hljs-number">1</span>]
|
||||
source = script.src <span class="hljs-keyword">or</span> script.getAttribute(<span class="hljs-string">'data-src'</span>)
|
||||
<span class="hljs-keyword">if</span> source
|
||||
CoffeeScript.load source,
|
||||
<span class="hljs-function"><span class="hljs-params">(param)</span> -></span>
|
||||
coffees[i] = param
|
||||
execute()
|
||||
options
|
||||
<span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
options.sourceFiles = [<span class="hljs-string">'embedded'</span>]
|
||||
coffees[i] = [script.innerHTML, options]
|
||||
|
||||
execute()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Listen for window load, both in decent browsers and in IE.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> <span class="hljs-built_in">window</span>.addEventListener
|
||||
<span class="hljs-built_in">window</span>.addEventListener <span class="hljs-string">'DOMContentLoaded'</span>, runScripts, <span class="hljs-literal">no</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-built_in">window</span>.attachEvent <span class="hljs-string">'onload'</span>, runScripts</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
345
docs/v1/annotated-source/cake.html
Normal file
@@ -0,0 +1,345 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>cake.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>cake.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p><code>cake</code> is a simplified version of <a href="http://www.gnu.org/software/make/">Make</a>
|
||||
(<a href="http://rake.rubyforge.org/">Rake</a>, <a href="http://github.com/280north/jake">Jake</a>)
|
||||
for CoffeeScript. You define tasks with names and descriptions in a Cakefile,
|
||||
and can call them from the command line, or invoke them from other tasks.</p>
|
||||
<p>Running <code>cake</code> with no arguments will print out a list of all the tasks in the
|
||||
current directory’s Cakefile.</p>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>External dependencies.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>fs = <span class="hljs-built_in">require</span> <span class="hljs-string">'fs'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span>
|
||||
helpers = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
optparse = <span class="hljs-built_in">require</span> <span class="hljs-string">'./optparse'</span>
|
||||
CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffee-script'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Register .coffee extension</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript.register()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Keep track of the list of defined tasks, the accepted options, and so on.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>tasks = {}
|
||||
options = {}
|
||||
switches = []
|
||||
oparse = <span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Mixin the top-level Cake functions for Cakefiles to use directly.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>helpers.extend <span class="hljs-built_in">global</span>,</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Define a Cake task with a short name, an optional sentence description,
|
||||
and the function to run as the action itself.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> task: <span class="hljs-function"><span class="hljs-params">(name, description, action)</span> -></span>
|
||||
[action, description] = [description, action] <span class="hljs-keyword">unless</span> action
|
||||
tasks[name] = {name, description, action}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Define an option that the Cakefile accepts. The parsed options hash,
|
||||
containing all of the command-line options passed, will be made available
|
||||
as the first argument to the action.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> option: <span class="hljs-function"><span class="hljs-params">(letter, flag, description)</span> -></span>
|
||||
switches.push [letter, flag, description]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Invoke another task in the current Cakefile.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> invoke: <span class="hljs-function"><span class="hljs-params">(name)</span> -></span>
|
||||
missingTask name <span class="hljs-keyword">unless</span> tasks[name]
|
||||
tasks[name].action options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Run <code>cake</code>. Executes all of the tasks you pass, in order. Note that Node’s
|
||||
asynchrony may cause tasks to execute in a different order than you’d expect.
|
||||
If no tasks are passed, print the help screen. Keep a reference to the
|
||||
original directory name, when running Cake tasks from subdirectories.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.run = <span class="hljs-function">-></span>
|
||||
<span class="hljs-built_in">global</span>.__originalDirname = fs.realpathSync <span class="hljs-string">'.'</span>
|
||||
process.chdir cakefileDirectory __originalDirname
|
||||
args = process.argv[<span class="hljs-number">2.</span>.]
|
||||
CoffeeScript.run fs.readFileSync(<span class="hljs-string">'Cakefile'</span>).toString(), filename: <span class="hljs-string">'Cakefile'</span>
|
||||
oparse = <span class="hljs-keyword">new</span> optparse.OptionParser switches
|
||||
<span class="hljs-keyword">return</span> printTasks() <span class="hljs-keyword">unless</span> args.length
|
||||
<span class="hljs-keyword">try</span>
|
||||
options = oparse.parse(args)
|
||||
<span class="hljs-keyword">catch</span> e
|
||||
<span class="hljs-keyword">return</span> fatalError <span class="hljs-string">"<span class="hljs-subst">#{e}</span>"</span>
|
||||
invoke arg <span class="hljs-keyword">for</span> arg <span class="hljs-keyword">in</span> options.arguments</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Display the list of Cake tasks in a format similar to <code>rake -T</code></p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">printTasks</span> = -></span>
|
||||
relative = path.relative <span class="hljs-keyword">or</span> path.resolve
|
||||
cakefilePath = path.join relative(__originalDirname, process.cwd()), <span class="hljs-string">'Cakefile'</span>
|
||||
<span class="hljs-built_in">console</span>.log <span class="hljs-string">"<span class="hljs-subst">#{cakefilePath}</span> defines the following tasks:\n"</span>
|
||||
<span class="hljs-keyword">for</span> name, task <span class="hljs-keyword">of</span> tasks
|
||||
spaces = <span class="hljs-number">20</span> - name.length
|
||||
spaces = <span class="hljs-keyword">if</span> spaces > <span class="hljs-number">0</span> <span class="hljs-keyword">then</span> Array(spaces + <span class="hljs-number">1</span>).join(<span class="hljs-string">' '</span>) <span class="hljs-keyword">else</span> <span class="hljs-string">''</span>
|
||||
desc = <span class="hljs-keyword">if</span> task.description <span class="hljs-keyword">then</span> <span class="hljs-string">"# <span class="hljs-subst">#{task.description}</span>"</span> <span class="hljs-keyword">else</span> <span class="hljs-string">''</span>
|
||||
<span class="hljs-built_in">console</span>.log <span class="hljs-string">"cake <span class="hljs-subst">#{name}</span><span class="hljs-subst">#{spaces}</span> <span class="hljs-subst">#{desc}</span>"</span>
|
||||
<span class="hljs-built_in">console</span>.log oparse.help() <span class="hljs-keyword">if</span> switches.length</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Print an error and exit when attempting to use an invalid task/option.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">fatalError</span> = <span class="hljs-params">(message)</span> -></span>
|
||||
<span class="hljs-built_in">console</span>.error message + <span class="hljs-string">'\n'</span>
|
||||
<span class="hljs-built_in">console</span>.log <span class="hljs-string">'To see a list of all tasks/options, run "cake"'</span>
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">missingTask</span> = <span class="hljs-params">(task)</span> -></span> fatalError <span class="hljs-string">"No such task: <span class="hljs-subst">#{task}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>When <code>cake</code> is invoked, search in the current and all parent directories
|
||||
to find the relevant Cakefile.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">cakefileDirectory</span> = <span class="hljs-params">(dir)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> dir <span class="hljs-keyword">if</span> fs.existsSync path.join dir, <span class="hljs-string">'Cakefile'</span>
|
||||
parent = path.normalize path.join dir, <span class="hljs-string">'..'</span>
|
||||
<span class="hljs-keyword">return</span> cakefileDirectory parent <span class="hljs-keyword">unless</span> parent <span class="hljs-keyword">is</span> dir
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"Cakefile not found in <span class="hljs-subst">#{process.cwd()}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
982
docs/v1/annotated-source/coffee-script.html
Normal file
@@ -0,0 +1,982 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>coffee-script.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>coffee-script.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>CoffeeScript can be used both on the server, as a command-line compiler based
|
||||
on Node.js/V8, or to run CoffeeScript directly in the browser. This module
|
||||
contains the main entry functions for tokenizing, parsing, and compiling
|
||||
source CoffeeScript into JavaScript.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>
|
||||
fs = <span class="hljs-built_in">require</span> <span class="hljs-string">'fs'</span>
|
||||
vm = <span class="hljs-built_in">require</span> <span class="hljs-string">'vm'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span>
|
||||
{Lexer} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./lexer'</span>
|
||||
{parser} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./parser'</span>
|
||||
helpers = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
SourceMap = <span class="hljs-built_in">require</span> <span class="hljs-string">'./sourcemap'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Require <code>package.json</code>, which is two levels above this file, as this file is
|
||||
evaluated from <code>lib/coffee-script</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>packageJson = <span class="hljs-built_in">require</span> <span class="hljs-string">'../../package.json'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>The current CoffeeScript version number.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.VERSION = packageJson.version
|
||||
|
||||
exports.FILE_EXTENSIONS = [<span class="hljs-string">'.coffee'</span>, <span class="hljs-string">'.litcoffee'</span>, <span class="hljs-string">'.coffee.md'</span>]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Expose helpers for testing.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.helpers = helpers</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Function that allows for btoa in both nodejs and the browser.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">base64encode</span> = <span class="hljs-params">(src)</span> -></span> <span class="hljs-keyword">switch</span>
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-keyword">typeof</span> Buffer <span class="hljs-keyword">is</span> <span class="hljs-string">'function'</span>
|
||||
<span class="hljs-keyword">new</span> Buffer(src).toString(<span class="hljs-string">'base64'</span>)
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-keyword">typeof</span> btoa <span class="hljs-keyword">is</span> <span class="hljs-string">'function'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>The contents of a <code><script></code> block are encoded via UTF-16, so if any extended
|
||||
characters are used in the block, btoa will fail as it maxes out at UTF-8.
|
||||
See <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowBase64/Base64_encoding_and_decoding#The_Unicode_Problem">https://developer.mozilla.org/en-US/docs/Web/API/WindowBase64/Base64_encoding_and_decoding#The_Unicode_Problem</a>
|
||||
for the gory details, and for the solution implemented here.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> btoa encodeURIComponent(src).replace <span class="hljs-regexp">/%([0-9A-F]{2})/g</span>, <span class="hljs-function"><span class="hljs-params">(match, p1)</span> -></span>
|
||||
String.fromCharCode <span class="hljs-string">'0x'</span> + p1
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error(<span class="hljs-string">'Unable to base64 encode inline sourcemap.'</span>)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Function wrapper to add source file information to SyntaxErrors thrown by the
|
||||
lexer/parser/compiler.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">withPrettyErrors</span> = <span class="hljs-params">(fn)</span> -></span>
|
||||
(code, options = {}) ->
|
||||
<span class="hljs-keyword">try</span>
|
||||
fn.call @, code, options
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">if</span> <span class="hljs-keyword">typeof</span> code <span class="hljs-keyword">isnt</span> <span class="hljs-string">'string'</span> <span class="hljs-comment"># Support `CoffeeScript.nodes(tokens)`.</span>
|
||||
<span class="hljs-keyword">throw</span> helpers.updateSyntaxError err, code, options.filename</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>For each compiled file, save its source in memory in case we need to
|
||||
recompile it later. We might need to recompile if the first compilation
|
||||
didn’t create a source map (faster) but something went wrong and we need
|
||||
a stack trace. Assuming that most of the time, code isn’t throwing
|
||||
exceptions, it’s probably more efficient to compile twice only when we
|
||||
need a stack trace, rather than always generating a source map even when
|
||||
it’s not likely to be used. Save in form of <code>filename</code>: <code>(source)</code></p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>sources = {}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Also save source maps if generated, in form of <code>filename</code>: <code>(source map)</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>sourceMaps = {}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Compile CoffeeScript code to JavaScript, using the Coffee/Jison compiler.</p>
|
||||
<p>If <code>options.sourceMap</code> is specified, then <code>options.filename</code> must also be
|
||||
specified. All options that can be passed to <code>SourceMap#generate</code> may also
|
||||
be passed here.</p>
|
||||
<p>This returns a javascript string, unless <code>options.sourceMap</code> is passed,
|
||||
in which case this returns a <code>{js, v3SourceMap, sourceMap}</code>
|
||||
object, where sourceMap is a sourcemap.coffee#SourceMap object, handy for
|
||||
doing programmatic lookups.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.compile = compile = withPrettyErrors (code, options) ->
|
||||
{merge, extend} = helpers
|
||||
options = extend {}, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Always generate a source map if no filename is passed in, since without a
|
||||
a filename we have no way to retrieve this source later in the event that
|
||||
we need to recompile it to get a source map for <code>prepareStackTrace</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> generateSourceMap = options.sourceMap <span class="hljs-keyword">or</span> options.inlineMap <span class="hljs-keyword">or</span> <span class="hljs-keyword">not</span> options.filename?
|
||||
filename = options.filename <span class="hljs-keyword">or</span> <span class="hljs-string">'<anonymous>'</span>
|
||||
|
||||
sources[filename] = code
|
||||
map = <span class="hljs-keyword">new</span> SourceMap <span class="hljs-keyword">if</span> generateSourceMap
|
||||
|
||||
tokens = lexer.tokenize code, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Pass a list of referenced variables, so that generated variables won’t get
|
||||
the same name.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> options.referencedVars = (
|
||||
token[<span class="hljs-number">1</span>] <span class="hljs-keyword">for</span> token <span class="hljs-keyword">in</span> tokens <span class="hljs-keyword">when</span> token[<span class="hljs-number">0</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">'IDENTIFIER'</span>
|
||||
)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Check for import or export; if found, force bare mode.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">unless</span> options.bare? <span class="hljs-keyword">and</span> options.bare <span class="hljs-keyword">is</span> <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">for</span> token <span class="hljs-keyword">in</span> tokens
|
||||
<span class="hljs-keyword">if</span> token[<span class="hljs-number">0</span>] <span class="hljs-keyword">in</span> [<span class="hljs-string">'IMPORT'</span>, <span class="hljs-string">'EXPORT'</span>]
|
||||
options.bare = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">break</span>
|
||||
|
||||
fragments = parser.parse(tokens).compileToFragments options
|
||||
|
||||
currentLine = <span class="hljs-number">0</span>
|
||||
currentLine += <span class="hljs-number">1</span> <span class="hljs-keyword">if</span> options.header
|
||||
currentLine += <span class="hljs-number">1</span> <span class="hljs-keyword">if</span> options.shiftLine
|
||||
currentColumn = <span class="hljs-number">0</span>
|
||||
js = <span class="hljs-string">""</span>
|
||||
<span class="hljs-keyword">for</span> fragment <span class="hljs-keyword">in</span> fragments</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Update the sourcemap with data from each fragment.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> generateSourceMap</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>Do not include empty, whitespace, or semicolon-only fragments.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> fragment.locationData <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> <span class="hljs-regexp">/^[;\s]*$/</span>.test fragment.code
|
||||
map.add(
|
||||
[fragment.locationData.first_line, fragment.locationData.first_column]
|
||||
[currentLine, currentColumn]
|
||||
{noReplace: <span class="hljs-literal">true</span>})
|
||||
newLines = helpers.count fragment.code, <span class="hljs-string">"\n"</span>
|
||||
currentLine += newLines
|
||||
<span class="hljs-keyword">if</span> newLines
|
||||
currentColumn = fragment.code.length - (fragment.code.lastIndexOf(<span class="hljs-string">"\n"</span>) + <span class="hljs-number">1</span>)
|
||||
<span class="hljs-keyword">else</span>
|
||||
currentColumn += fragment.code.length</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>Copy the code from each fragment into the final JavaScript.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> js += fragment.code
|
||||
|
||||
<span class="hljs-keyword">if</span> options.header
|
||||
header = <span class="hljs-string">"Generated by CoffeeScript <span class="hljs-subst">#{@VERSION}</span>"</span>
|
||||
js = <span class="hljs-string">"// <span class="hljs-subst">#{header}</span>\n<span class="hljs-subst">#{js}</span>"</span>
|
||||
|
||||
<span class="hljs-keyword">if</span> generateSourceMap
|
||||
v3SourceMap = map.generate(options, code)
|
||||
sourceMaps[filename] = map
|
||||
|
||||
<span class="hljs-keyword">if</span> options.inlineMap
|
||||
encoded = base64encode JSON.stringify v3SourceMap
|
||||
sourceMapDataURI = <span class="hljs-string">"//# sourceMappingURL=data:application/json;base64,<span class="hljs-subst">#{encoded}</span>"</span>
|
||||
sourceURL = <span class="hljs-string">"//# sourceURL=<span class="hljs-subst">#{options.filename ? <span class="hljs-string">'coffeescript'</span>}</span>"</span>
|
||||
js = <span class="hljs-string">"<span class="hljs-subst">#{js}</span>\n<span class="hljs-subst">#{sourceMapDataURI}</span>\n<span class="hljs-subst">#{sourceURL}</span>"</span>
|
||||
|
||||
<span class="hljs-keyword">if</span> options.sourceMap
|
||||
{
|
||||
js
|
||||
sourceMap: map
|
||||
v3SourceMap: JSON.stringify v3SourceMap, <span class="hljs-literal">null</span>, <span class="hljs-number">2</span>
|
||||
}
|
||||
<span class="hljs-keyword">else</span>
|
||||
js</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>Tokenize a string of CoffeeScript code, and return the array of tokens.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.tokens = withPrettyErrors (code, options) ->
|
||||
lexer.tokenize code, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>Parse a string of CoffeeScript code or an array of lexed tokens, and
|
||||
return the AST. You can then compile it by calling <code>.compile()</code> on the root,
|
||||
or traverse it by using <code>.traverseChildren()</code> with a callback.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.nodes = withPrettyErrors (source, options) ->
|
||||
<span class="hljs-keyword">if</span> <span class="hljs-keyword">typeof</span> source <span class="hljs-keyword">is</span> <span class="hljs-string">'string'</span>
|
||||
parser.parse lexer.tokenize source, options
|
||||
<span class="hljs-keyword">else</span>
|
||||
parser.parse source</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Compile and execute a string of CoffeeScript (on the server), correctly
|
||||
setting <code>__filename</code>, <code>__dirname</code>, and relative <code>require()</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.run = <span class="hljs-function"><span class="hljs-params">(code, options = {})</span> -></span>
|
||||
mainModule = <span class="hljs-built_in">require</span>.main</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<p>Set the filename.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> mainModule.filename = process.argv[<span class="hljs-number">1</span>] =
|
||||
<span class="hljs-keyword">if</span> options.filename <span class="hljs-keyword">then</span> fs.realpathSync(options.filename) <span class="hljs-keyword">else</span> <span class="hljs-string">'<anonymous>'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
<p>Clear the module cache.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> mainModule.moduleCache <span class="hljs-keyword">and</span>= {}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>Assign paths for node_modules loading</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> dir = <span class="hljs-keyword">if</span> options.filename?
|
||||
path.dirname fs.realpathSync options.filename
|
||||
<span class="hljs-keyword">else</span>
|
||||
fs.realpathSync <span class="hljs-string">'.'</span>
|
||||
mainModule.paths = <span class="hljs-built_in">require</span>(<span class="hljs-string">'module'</span>)._nodeModulePaths dir</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-23">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-23">¶</a>
|
||||
</div>
|
||||
<p>Compile.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> helpers.isCoffee(mainModule.filename) <span class="hljs-keyword">or</span> <span class="hljs-built_in">require</span>.extensions
|
||||
answer = compile code, options
|
||||
code = answer.js ? answer
|
||||
|
||||
mainModule._compile code, mainModule.filename</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-24">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-24">¶</a>
|
||||
</div>
|
||||
<p>Compile and evaluate a string of CoffeeScript (in a Node.js-like environment).
|
||||
The CoffeeScript REPL uses this to run the input.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.eval = <span class="hljs-function"><span class="hljs-params">(code, options = {})</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> code = code.trim()
|
||||
createContext = vm.Script.createContext ? vm.createContext
|
||||
|
||||
isContext = vm.isContext ? (ctx) ->
|
||||
options.sandbox <span class="hljs-keyword">instanceof</span> createContext().constructor
|
||||
|
||||
<span class="hljs-keyword">if</span> createContext
|
||||
<span class="hljs-keyword">if</span> options.sandbox?
|
||||
<span class="hljs-keyword">if</span> isContext options.sandbox
|
||||
sandbox = options.sandbox
|
||||
<span class="hljs-keyword">else</span>
|
||||
sandbox = createContext()
|
||||
sandbox[k] = v <span class="hljs-keyword">for</span> own k, v <span class="hljs-keyword">of</span> options.sandbox
|
||||
sandbox.<span class="hljs-built_in">global</span> = sandbox.root = sandbox.GLOBAL = sandbox
|
||||
<span class="hljs-keyword">else</span>
|
||||
sandbox = <span class="hljs-built_in">global</span>
|
||||
sandbox.__filename = options.filename || <span class="hljs-string">'eval'</span>
|
||||
sandbox.__dirname = path.dirname sandbox.__filename</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-25">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-25">¶</a>
|
||||
</div>
|
||||
<p>define module/require only if they chose not to specify their own</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">unless</span> sandbox <span class="hljs-keyword">isnt</span> <span class="hljs-built_in">global</span> <span class="hljs-keyword">or</span> sandbox.<span class="hljs-built_in">module</span> <span class="hljs-keyword">or</span> sandbox.<span class="hljs-built_in">require</span>
|
||||
Module = <span class="hljs-built_in">require</span> <span class="hljs-string">'module'</span>
|
||||
sandbox.<span class="hljs-built_in">module</span> = _module = <span class="hljs-keyword">new</span> Module(options.modulename || <span class="hljs-string">'eval'</span>)
|
||||
sandbox.<span class="hljs-built_in">require</span> = _require = <span class="hljs-function"><span class="hljs-params">(path)</span> -></span> Module._load path, _module, <span class="hljs-literal">true</span>
|
||||
_module.filename = sandbox.__filename
|
||||
<span class="hljs-keyword">for</span> r <span class="hljs-keyword">in</span> Object.getOwnPropertyNames <span class="hljs-built_in">require</span> <span class="hljs-keyword">when</span> r <span class="hljs-keyword">not</span> <span class="hljs-keyword">in</span> [<span class="hljs-string">'paths'</span>, <span class="hljs-string">'arguments'</span>, <span class="hljs-string">'caller'</span>]
|
||||
_require[r] = <span class="hljs-built_in">require</span>[r]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-26">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-26">¶</a>
|
||||
</div>
|
||||
<p>use the same hack node currently uses for their own REPL</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> _require.paths = _module.paths = Module._nodeModulePaths process.cwd()
|
||||
_require.resolve = <span class="hljs-function"><span class="hljs-params">(request)</span> -></span> Module._resolveFilename request, _module
|
||||
o = {}
|
||||
o[k] = v <span class="hljs-keyword">for</span> own k, v <span class="hljs-keyword">of</span> options
|
||||
o.bare = <span class="hljs-literal">on</span> <span class="hljs-comment"># ensure return value</span>
|
||||
js = compile code, o
|
||||
<span class="hljs-keyword">if</span> sandbox <span class="hljs-keyword">is</span> <span class="hljs-built_in">global</span>
|
||||
vm.runInThisContext js
|
||||
<span class="hljs-keyword">else</span>
|
||||
vm.runInContext js, sandbox
|
||||
|
||||
exports.register = <span class="hljs-function">-></span> <span class="hljs-built_in">require</span> <span class="hljs-string">'./register'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-27">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-27">¶</a>
|
||||
</div>
|
||||
<p>Throw error with deprecation warning when depending upon implicit <code>require.extensions</code> registration</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> <span class="hljs-built_in">require</span>.extensions
|
||||
<span class="hljs-keyword">for</span> ext <span class="hljs-keyword">in</span> @FILE_EXTENSIONS <span class="hljs-keyword">then</span> <span class="hljs-keyword">do</span> (ext) ->
|
||||
<span class="hljs-built_in">require</span>.extensions[ext] ?= <span class="hljs-function">-></span>
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"""
|
||||
Use CoffeeScript.register() or require the coffee-script/register module to require <span class="hljs-subst">#{ext}</span> files.
|
||||
"""</span>
|
||||
|
||||
exports._compileFile = <span class="hljs-function"><span class="hljs-params">(filename, sourceMap = <span class="hljs-literal">no</span>, inlineMap = <span class="hljs-literal">no</span>)</span> -></span>
|
||||
raw = fs.readFileSync filename, <span class="hljs-string">'utf8'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-28">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-28">¶</a>
|
||||
</div>
|
||||
<p>Strip the Unicode byte order mark, if this file begins with one.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> stripped = <span class="hljs-keyword">if</span> raw.charCodeAt(<span class="hljs-number">0</span>) <span class="hljs-keyword">is</span> <span class="hljs-number">0xFEFF</span> <span class="hljs-keyword">then</span> raw.substring <span class="hljs-number">1</span> <span class="hljs-keyword">else</span> raw
|
||||
|
||||
<span class="hljs-keyword">try</span>
|
||||
answer = compile stripped, {
|
||||
filename, sourceMap, inlineMap
|
||||
sourceFiles: [filename]
|
||||
literate: helpers.isLiterate filename
|
||||
}
|
||||
<span class="hljs-keyword">catch</span> err</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-29">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-29">¶</a>
|
||||
</div>
|
||||
<p>As the filename and code of a dynamically loaded file will be different
|
||||
from the original file compiled with CoffeeScript.run, add that
|
||||
information to error so it can be pretty-printed later.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">throw</span> helpers.updateSyntaxError err, stripped, filename
|
||||
|
||||
answer</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-30">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-30">¶</a>
|
||||
</div>
|
||||
<p>Instantiate a Lexer for our use here.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>lexer = <span class="hljs-keyword">new</span> Lexer</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-31">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-31">¶</a>
|
||||
</div>
|
||||
<p>The real Lexer produces a generic stream of tokens. This object provides a
|
||||
thin wrapper around it, compatible with the Jison API. We can then pass it
|
||||
directly as a “Jison lexer”.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>parser.lexer =
|
||||
lex: <span class="hljs-function">-></span>
|
||||
token = parser.tokens[@pos++]
|
||||
<span class="hljs-keyword">if</span> token
|
||||
[tag, @yytext, @yylloc] = token
|
||||
parser.errorToken = token.origin <span class="hljs-keyword">or</span> token
|
||||
@yylineno = @yylloc.first_line
|
||||
<span class="hljs-keyword">else</span>
|
||||
tag = <span class="hljs-string">''</span>
|
||||
|
||||
tag
|
||||
setInput: <span class="hljs-function"><span class="hljs-params">(tokens)</span> -></span>
|
||||
parser.tokens = tokens
|
||||
@pos = <span class="hljs-number">0</span>
|
||||
upcomingInput: <span class="hljs-function">-></span>
|
||||
<span class="hljs-string">""</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-32">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-32">¶</a>
|
||||
</div>
|
||||
<p>Make all the AST nodes visible to the parser.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>parser.yy = <span class="hljs-built_in">require</span> <span class="hljs-string">'./nodes'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-33">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-33">¶</a>
|
||||
</div>
|
||||
<p>Override Jison’s default error handling function.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>parser.yy.parseError = <span class="hljs-function"><span class="hljs-params">(message, {token})</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-34">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-34">¶</a>
|
||||
</div>
|
||||
<p>Disregard Jison’s message, it contains redundant line number information.
|
||||
Disregard the token, we take its value directly from the lexer in case
|
||||
the error is caused by a generated token which might refer to its origin.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> {errorToken, tokens} = parser
|
||||
[errorTag, errorText, errorLoc] = errorToken
|
||||
|
||||
errorText = <span class="hljs-keyword">switch</span>
|
||||
<span class="hljs-keyword">when</span> errorToken <span class="hljs-keyword">is</span> tokens[tokens.length - <span class="hljs-number">1</span>]
|
||||
<span class="hljs-string">'end of input'</span>
|
||||
<span class="hljs-keyword">when</span> errorTag <span class="hljs-keyword">in</span> [<span class="hljs-string">'INDENT'</span>, <span class="hljs-string">'OUTDENT'</span>]
|
||||
<span class="hljs-string">'indentation'</span>
|
||||
<span class="hljs-keyword">when</span> errorTag <span class="hljs-keyword">in</span> [<span class="hljs-string">'IDENTIFIER'</span>, <span class="hljs-string">'NUMBER'</span>, <span class="hljs-string">'INFINITY'</span>, <span class="hljs-string">'STRING'</span>, <span class="hljs-string">'STRING_START'</span>, <span class="hljs-string">'REGEX'</span>, <span class="hljs-string">'REGEX_START'</span>]
|
||||
errorTag.replace(<span class="hljs-regexp">/_START$/</span>, <span class="hljs-string">''</span>).toLowerCase()
|
||||
<span class="hljs-keyword">else</span>
|
||||
helpers.nameWhitespaceCharacter errorText</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-35">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-35">¶</a>
|
||||
</div>
|
||||
<p>The second argument has a <code>loc</code> property, which should have the location
|
||||
data for this token. Unfortunately, Jison seems to send an outdated <code>loc</code>
|
||||
(from the previous token), so we take the location information directly
|
||||
from the lexer.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> helpers.throwSyntaxError <span class="hljs-string">"unexpected <span class="hljs-subst">#{errorText}</span>"</span>, errorLoc</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-36">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-36">¶</a>
|
||||
</div>
|
||||
<p>Based on <a href="http://v8.googlecode.com/svn/branches/bleeding_edge/src/messages.js">http://v8.googlecode.com/svn/branches/bleeding_edge/src/messages.js</a>
|
||||
Modified to handle sourceMap</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">formatSourcePosition</span> = <span class="hljs-params">(frame, getSourceMapping)</span> -></span>
|
||||
filename = <span class="hljs-literal">undefined</span>
|
||||
fileLocation = <span class="hljs-string">''</span>
|
||||
|
||||
<span class="hljs-keyword">if</span> frame.isNative()
|
||||
fileLocation = <span class="hljs-string">"native"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-keyword">if</span> frame.isEval()
|
||||
filename = frame.getScriptNameOrSourceURL()
|
||||
fileLocation = <span class="hljs-string">"<span class="hljs-subst">#{frame.getEvalOrigin()}</span>, "</span> <span class="hljs-keyword">unless</span> filename
|
||||
<span class="hljs-keyword">else</span>
|
||||
filename = frame.getFileName()
|
||||
|
||||
filename <span class="hljs-keyword">or</span>= <span class="hljs-string">"<anonymous>"</span>
|
||||
|
||||
line = frame.getLineNumber()
|
||||
column = frame.getColumnNumber()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-37">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-37">¶</a>
|
||||
</div>
|
||||
<p>Check for a sourceMap position</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> source = getSourceMapping filename, line, column
|
||||
fileLocation =
|
||||
<span class="hljs-keyword">if</span> source
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{filename}</span>:<span class="hljs-subst">#{source[<span class="hljs-number">0</span>]}</span>:<span class="hljs-subst">#{source[<span class="hljs-number">1</span>]}</span>"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{filename}</span>:<span class="hljs-subst">#{line}</span>:<span class="hljs-subst">#{column}</span>"</span>
|
||||
|
||||
functionName = frame.getFunctionName()
|
||||
isConstructor = frame.isConstructor()
|
||||
isMethodCall = <span class="hljs-keyword">not</span> (frame.isToplevel() <span class="hljs-keyword">or</span> isConstructor)
|
||||
|
||||
<span class="hljs-keyword">if</span> isMethodCall
|
||||
methodName = frame.getMethodName()
|
||||
typeName = frame.getTypeName()
|
||||
|
||||
<span class="hljs-keyword">if</span> functionName
|
||||
tp = <span class="hljs-keyword">as</span> = <span class="hljs-string">''</span>
|
||||
<span class="hljs-keyword">if</span> typeName <span class="hljs-keyword">and</span> functionName.indexOf typeName
|
||||
tp = <span class="hljs-string">"<span class="hljs-subst">#{typeName}</span>."</span>
|
||||
<span class="hljs-keyword">if</span> methodName <span class="hljs-keyword">and</span> functionName.indexOf(<span class="hljs-string">".<span class="hljs-subst">#{methodName}</span>"</span>) <span class="hljs-keyword">isnt</span> functionName.length - methodName.length - <span class="hljs-number">1</span>
|
||||
<span class="hljs-keyword">as</span> = <span class="hljs-string">" [as <span class="hljs-subst">#{methodName}</span>]"</span>
|
||||
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{tp}</span><span class="hljs-subst">#{functionName}</span><span class="hljs-subst">#{<span class="hljs-keyword">as</span>}</span> (<span class="hljs-subst">#{fileLocation}</span>)"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{typeName}</span>.<span class="hljs-subst">#{methodName <span class="hljs-keyword">or</span> <span class="hljs-string">'<anonymous>'</span>}</span> (<span class="hljs-subst">#{fileLocation}</span>)"</span>
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> isConstructor
|
||||
<span class="hljs-string">"new <span class="hljs-subst">#{functionName <span class="hljs-keyword">or</span> <span class="hljs-string">'<anonymous>'</span>}</span> (<span class="hljs-subst">#{fileLocation}</span>)"</span>
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> functionName
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{functionName}</span> (<span class="hljs-subst">#{fileLocation}</span>)"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
fileLocation
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">getSourceMap</span> = <span class="hljs-params">(filename)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> sourceMaps[filename]?
|
||||
sourceMaps[filename]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-38">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-38">¶</a>
|
||||
</div>
|
||||
<p>CoffeeScript compiled in a browser may get compiled with <code>options.filename</code>
|
||||
of <code><anonymous></code>, but the browser may request the stack trace with the
|
||||
filename of the script file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> sourceMaps[<span class="hljs-string">'<anonymous>'</span>]?
|
||||
sourceMaps[<span class="hljs-string">'<anonymous>'</span>]
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> sources[filename]?
|
||||
answer = compile sources[filename],
|
||||
filename: filename
|
||||
sourceMap: <span class="hljs-literal">yes</span>
|
||||
literate: helpers.isLiterate filename
|
||||
answer.sourceMap
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-39">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-39">¶</a>
|
||||
</div>
|
||||
<p>Based on <a href="http://goo.gl/ZTx1p">michaelficarra/CoffeeScriptRedux</a>
|
||||
NodeJS / V8 have no support for transforming positions in stack traces using
|
||||
sourceMap, so we must monkey-patch Error to display CoffeeScript source
|
||||
positions.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>Error.prepareStackTrace = <span class="hljs-function"><span class="hljs-params">(err, stack)</span> -></span>
|
||||
<span class="hljs-function"> <span class="hljs-title">getSourceMapping</span> = <span class="hljs-params">(filename, line, column)</span> -></span>
|
||||
sourceMap = getSourceMap filename
|
||||
answer = sourceMap.sourceLocation [line - <span class="hljs-number">1</span>, column - <span class="hljs-number">1</span>] <span class="hljs-keyword">if</span> sourceMap?
|
||||
<span class="hljs-keyword">if</span> answer? <span class="hljs-keyword">then</span> [answer[<span class="hljs-number">0</span>] + <span class="hljs-number">1</span>, answer[<span class="hljs-number">1</span>] + <span class="hljs-number">1</span>] <span class="hljs-keyword">else</span> <span class="hljs-literal">null</span>
|
||||
|
||||
frames = <span class="hljs-keyword">for</span> frame <span class="hljs-keyword">in</span> stack
|
||||
<span class="hljs-keyword">break</span> <span class="hljs-keyword">if</span> frame.getFunction() <span class="hljs-keyword">is</span> exports.run
|
||||
<span class="hljs-string">" at <span class="hljs-subst">#{formatSourcePosition frame, getSourceMapping}</span>"</span>
|
||||
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{err.toString()}</span>\n<span class="hljs-subst">#{frames.join <span class="hljs-string">'\n'</span>}</span>\n"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
882
docs/v1/annotated-source/command.html
Normal file
@@ -0,0 +1,882 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>command.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>command.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>The <code>coffee</code> utility. Handles command-line compilation of CoffeeScript
|
||||
into various forms: saved into <code>.js</code> files or printed to stdout
|
||||
or recompiled every time the source is saved,
|
||||
printed as a token stream or as the syntax tree, or launch an
|
||||
interactive REPL.</p>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>External dependencies.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>fs = <span class="hljs-built_in">require</span> <span class="hljs-string">'fs'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span>
|
||||
helpers = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
optparse = <span class="hljs-built_in">require</span> <span class="hljs-string">'./optparse'</span>
|
||||
CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffee-script'</span>
|
||||
{spawn, exec} = <span class="hljs-built_in">require</span> <span class="hljs-string">'child_process'</span>
|
||||
{EventEmitter} = <span class="hljs-built_in">require</span> <span class="hljs-string">'events'</span>
|
||||
|
||||
useWinPathSep = path.sep <span class="hljs-keyword">is</span> <span class="hljs-string">'\\'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Allow CoffeeScript to emit Node.js events.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>helpers.extend CoffeeScript, <span class="hljs-keyword">new</span> EventEmitter
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">printLine</span> = <span class="hljs-params">(line)</span> -></span> process.stdout.write line + <span class="hljs-string">'\n'</span>
|
||||
<span class="hljs-function"><span class="hljs-title">printWarn</span> = <span class="hljs-params">(line)</span> -></span> process.stderr.write line + <span class="hljs-string">'\n'</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">hidden</span> = <span class="hljs-params">(file)</span> -></span> <span class="hljs-regexp">/^\.|~$/</span>.test file</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>The help banner that is printed in conjunction with <code>-h</code>/<code>--help</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>BANNER = <span class="hljs-string">'''
|
||||
Usage: coffee [options] path/to/script.coffee -- [args]
|
||||
|
||||
If called without options, `coffee` will run your script.
|
||||
'''</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>The list of all the valid option flags that <code>coffee</code> knows how to handle.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>SWITCHES = [
|
||||
[<span class="hljs-string">'-b'</span>, <span class="hljs-string">'--bare'</span>, <span class="hljs-string">'compile without a top-level function wrapper'</span>]
|
||||
[<span class="hljs-string">'-c'</span>, <span class="hljs-string">'--compile'</span>, <span class="hljs-string">'compile to JavaScript and save as .js files'</span>]
|
||||
[<span class="hljs-string">'-e'</span>, <span class="hljs-string">'--eval'</span>, <span class="hljs-string">'pass a string from the command line as input'</span>]
|
||||
[<span class="hljs-string">'-h'</span>, <span class="hljs-string">'--help'</span>, <span class="hljs-string">'display this help message'</span>]
|
||||
[<span class="hljs-string">'-i'</span>, <span class="hljs-string">'--interactive'</span>, <span class="hljs-string">'run an interactive CoffeeScript REPL'</span>]
|
||||
[<span class="hljs-string">'-j'</span>, <span class="hljs-string">'--join [FILE]'</span>, <span class="hljs-string">'concatenate the source CoffeeScript before compiling'</span>]
|
||||
[<span class="hljs-string">'-m'</span>, <span class="hljs-string">'--map'</span>, <span class="hljs-string">'generate source map and save as .js.map files'</span>]
|
||||
[<span class="hljs-string">'-M'</span>, <span class="hljs-string">'--inline-map'</span>, <span class="hljs-string">'generate source map and include it directly in output'</span>]
|
||||
[<span class="hljs-string">'-n'</span>, <span class="hljs-string">'--nodes'</span>, <span class="hljs-string">'print out the parse tree that the parser produces'</span>]
|
||||
[ <span class="hljs-string">'--nodejs [ARGS]'</span>, <span class="hljs-string">'pass options directly to the "node" binary'</span>]
|
||||
[ <span class="hljs-string">'--no-header'</span>, <span class="hljs-string">'suppress the "Generated by" header'</span>]
|
||||
[<span class="hljs-string">'-o'</span>, <span class="hljs-string">'--output [DIR]'</span>, <span class="hljs-string">'set the output directory for compiled JavaScript'</span>]
|
||||
[<span class="hljs-string">'-p'</span>, <span class="hljs-string">'--print'</span>, <span class="hljs-string">'print out the compiled JavaScript'</span>]
|
||||
[<span class="hljs-string">'-r'</span>, <span class="hljs-string">'--require [MODULE*]'</span>, <span class="hljs-string">'require the given module before eval or REPL'</span>]
|
||||
[<span class="hljs-string">'-s'</span>, <span class="hljs-string">'--stdio'</span>, <span class="hljs-string">'listen for and compile scripts over stdio'</span>]
|
||||
[<span class="hljs-string">'-l'</span>, <span class="hljs-string">'--literate'</span>, <span class="hljs-string">'treat stdio as literate style coffee-script'</span>]
|
||||
[<span class="hljs-string">'-t'</span>, <span class="hljs-string">'--tokens'</span>, <span class="hljs-string">'print out the tokens that the lexer/rewriter produce'</span>]
|
||||
[<span class="hljs-string">'-v'</span>, <span class="hljs-string">'--version'</span>, <span class="hljs-string">'display the version number'</span>]
|
||||
[<span class="hljs-string">'-w'</span>, <span class="hljs-string">'--watch'</span>, <span class="hljs-string">'watch scripts for changes and rerun commands'</span>]
|
||||
]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Top-level objects shared by all the functions.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>opts = {}
|
||||
sources = []
|
||||
sourceCode = []
|
||||
notSources = {}
|
||||
watchedDirs = {}
|
||||
optionParser = <span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Run <code>coffee</code> by parsing passed options and determining what action to take.
|
||||
Many flags cause us to divert before compiling anything. Flags passed after
|
||||
<code>--</code> will be passed verbatim to your script as arguments in <code>process.argv</code></p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.run = <span class="hljs-function">-></span>
|
||||
parseOptions()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Make the REPL <em>CLI</em> use the global context so as to (a) be consistent with the
|
||||
<code>node</code> REPL CLI and, therefore, (b) make packages that modify native prototypes
|
||||
(such as ‘colors’ and ‘sugar’) work as expected.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> replCliOpts = useGlobal: <span class="hljs-literal">yes</span>
|
||||
opts.prelude = makePrelude opts.<span class="hljs-built_in">require</span> <span class="hljs-keyword">if</span> opts.<span class="hljs-built_in">require</span>
|
||||
replCliOpts.prelude = opts.prelude
|
||||
<span class="hljs-keyword">return</span> forkNode() <span class="hljs-keyword">if</span> opts.nodejs
|
||||
<span class="hljs-keyword">return</span> usage() <span class="hljs-keyword">if</span> opts.help
|
||||
<span class="hljs-keyword">return</span> version() <span class="hljs-keyword">if</span> opts.version
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-built_in">require</span>(<span class="hljs-string">'./repl'</span>).start(replCliOpts) <span class="hljs-keyword">if</span> opts.interactive
|
||||
<span class="hljs-keyword">return</span> compileStdio() <span class="hljs-keyword">if</span> opts.stdio
|
||||
<span class="hljs-keyword">return</span> compileScript <span class="hljs-literal">null</span>, opts.arguments[<span class="hljs-number">0</span>] <span class="hljs-keyword">if</span> opts.eval
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-built_in">require</span>(<span class="hljs-string">'./repl'</span>).start(replCliOpts) <span class="hljs-keyword">unless</span> opts.arguments.length
|
||||
literals = <span class="hljs-keyword">if</span> opts.run <span class="hljs-keyword">then</span> opts.arguments.splice <span class="hljs-number">1</span> <span class="hljs-keyword">else</span> []
|
||||
process.argv = process.argv[<span class="hljs-number">0.</span><span class="hljs-number">.1</span>].concat literals
|
||||
process.argv[<span class="hljs-number">0</span>] = <span class="hljs-string">'coffee'</span>
|
||||
|
||||
opts.output = path.resolve opts.output <span class="hljs-keyword">if</span> opts.output
|
||||
<span class="hljs-keyword">if</span> opts.join
|
||||
opts.join = path.resolve opts.join
|
||||
<span class="hljs-built_in">console</span>.error <span class="hljs-string">'''
|
||||
|
||||
The --join option is deprecated and will be removed in a future version.
|
||||
|
||||
If for some reason it's necessary to share local variables between files,
|
||||
replace...
|
||||
|
||||
$ coffee --compile --join bundle.js -- a.coffee b.coffee c.coffee
|
||||
|
||||
with...
|
||||
|
||||
$ cat a.coffee b.coffee c.coffee | coffee --compile --stdio > bundle.js
|
||||
|
||||
'''</span>
|
||||
<span class="hljs-keyword">for</span> source <span class="hljs-keyword">in</span> opts.arguments
|
||||
source = path.resolve source
|
||||
compilePath source, <span class="hljs-literal">yes</span>, source
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">makePrelude</span> = <span class="hljs-params">(requires)</span> -></span>
|
||||
requires.map (<span class="hljs-built_in">module</span>) ->
|
||||
[_, name, <span class="hljs-built_in">module</span>] = match <span class="hljs-keyword">if</span> match = <span class="hljs-built_in">module</span>.match(<span class="hljs-regexp">/^(.*)=(.*)$/</span>)
|
||||
name ||= helpers.baseFileName <span class="hljs-built_in">module</span>, <span class="hljs-literal">yes</span>, useWinPathSep
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{name}</span> = require('<span class="hljs-subst">#{<span class="hljs-built_in">module</span>}</span>')"</span>
|
||||
.join <span class="hljs-string">';'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Compile a path, which could be a script or a directory. If a directory
|
||||
is passed, recursively compile all ‘.coffee’, ‘.litcoffee’, and ‘.coffee.md’
|
||||
extension source files in it and all subdirectories.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">compilePath</span> = <span class="hljs-params">(source, topLevel, base)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> source <span class="hljs-keyword">in</span> sources <span class="hljs-keyword">or</span>
|
||||
watchedDirs[source] <span class="hljs-keyword">or</span>
|
||||
<span class="hljs-keyword">not</span> topLevel <span class="hljs-keyword">and</span> (notSources[source] <span class="hljs-keyword">or</span> hidden source)
|
||||
<span class="hljs-keyword">try</span>
|
||||
stats = fs.statSync source
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">if</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-built_in">console</span>.error <span class="hljs-string">"File not found: <span class="hljs-subst">#{source}</span>"</span>
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
<span class="hljs-keyword">throw</span> err
|
||||
<span class="hljs-keyword">if</span> stats.isDirectory()
|
||||
<span class="hljs-keyword">if</span> path.basename(source) <span class="hljs-keyword">is</span> <span class="hljs-string">'node_modules'</span>
|
||||
notSources[source] = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">return</span>
|
||||
<span class="hljs-keyword">if</span> opts.run
|
||||
compilePath findDirectoryIndex(source), topLevel, base
|
||||
<span class="hljs-keyword">return</span>
|
||||
watchDir source, base <span class="hljs-keyword">if</span> opts.watch
|
||||
<span class="hljs-keyword">try</span>
|
||||
files = fs.readdirSync source
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">if</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span> <span class="hljs-keyword">then</span> <span class="hljs-keyword">return</span> <span class="hljs-keyword">else</span> <span class="hljs-keyword">throw</span> err
|
||||
<span class="hljs-keyword">for</span> file <span class="hljs-keyword">in</span> files
|
||||
compilePath (path.join source, file), <span class="hljs-literal">no</span>, base
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> topLevel <span class="hljs-keyword">or</span> helpers.isCoffee source
|
||||
sources.push source
|
||||
sourceCode.push <span class="hljs-literal">null</span>
|
||||
<span class="hljs-keyword">delete</span> notSources[source]
|
||||
watch source, base <span class="hljs-keyword">if</span> opts.watch
|
||||
<span class="hljs-keyword">try</span>
|
||||
code = fs.readFileSync source
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">if</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span> <span class="hljs-keyword">then</span> <span class="hljs-keyword">return</span> <span class="hljs-keyword">else</span> <span class="hljs-keyword">throw</span> err
|
||||
compileScript(source, code.toString(), base)
|
||||
<span class="hljs-keyword">else</span>
|
||||
notSources[source] = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">findDirectoryIndex</span> = <span class="hljs-params">(source)</span> -></span>
|
||||
<span class="hljs-keyword">for</span> ext <span class="hljs-keyword">in</span> CoffeeScript.FILE_EXTENSIONS
|
||||
index = path.join source, <span class="hljs-string">"index<span class="hljs-subst">#{ext}</span>"</span>
|
||||
<span class="hljs-keyword">try</span>
|
||||
<span class="hljs-keyword">return</span> index <span class="hljs-keyword">if</span> (fs.statSync index).isFile()
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-built_in">console</span>.error <span class="hljs-string">"Missing index.coffee or index.litcoffee in <span class="hljs-subst">#{source}</span>"</span>
|
||||
process.exit <span class="hljs-number">1</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Compile a single source script, containing the given code, according to the
|
||||
requested options. If evaluating the script directly sets <code>__filename</code>,
|
||||
<code>__dirname</code> and <code>module.filename</code> to be correct relative to the script’s path.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">compileScript</span> = <span class="hljs-params">(file, input, base = <span class="hljs-literal">null</span>)</span> -></span>
|
||||
o = opts
|
||||
options = compileOptions file, base
|
||||
<span class="hljs-keyword">try</span>
|
||||
t = task = {file, input, options}
|
||||
CoffeeScript.emit <span class="hljs-string">'compile'</span>, task
|
||||
<span class="hljs-keyword">if</span> o.tokens
|
||||
printTokens CoffeeScript.tokens t.input, t.options
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.nodes
|
||||
printLine CoffeeScript.nodes(t.input, t.options).toString().trim()
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.run
|
||||
CoffeeScript.register()
|
||||
CoffeeScript.eval opts.prelude, t.options <span class="hljs-keyword">if</span> opts.prelude
|
||||
CoffeeScript.run t.input, t.options
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.join <span class="hljs-keyword">and</span> t.file <span class="hljs-keyword">isnt</span> o.join
|
||||
t.input = helpers.invertLiterate t.input <span class="hljs-keyword">if</span> helpers.isLiterate file
|
||||
sourceCode[sources.indexOf(t.file)] = t.input
|
||||
compileJoin()
|
||||
<span class="hljs-keyword">else</span>
|
||||
compiled = CoffeeScript.compile t.input, t.options
|
||||
t.output = compiled
|
||||
<span class="hljs-keyword">if</span> o.map
|
||||
t.output = compiled.js
|
||||
t.sourceMap = compiled.v3SourceMap
|
||||
|
||||
CoffeeScript.emit <span class="hljs-string">'success'</span>, task
|
||||
<span class="hljs-keyword">if</span> o.<span class="hljs-built_in">print</span>
|
||||
printLine t.output.trim()
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.compile <span class="hljs-keyword">or</span> o.map
|
||||
writeJs base, t.file, t.output, options.jsPath, t.sourceMap
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
CoffeeScript.emit <span class="hljs-string">'failure'</span>, err, task
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> CoffeeScript.listeners(<span class="hljs-string">'failure'</span>).length
|
||||
message = err?.stack <span class="hljs-keyword">or</span> <span class="hljs-string">"<span class="hljs-subst">#{err}</span>"</span>
|
||||
<span class="hljs-keyword">if</span> o.watch
|
||||
printLine message + <span class="hljs-string">'\x07'</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
printWarn message
|
||||
process.exit <span class="hljs-number">1</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Attach the appropriate listeners to compile scripts incoming over <strong>stdin</strong>,
|
||||
and write them back to <strong>stdout</strong>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">compileStdio</span> = -></span>
|
||||
buffers = []
|
||||
stdin = process.openStdin()
|
||||
stdin.<span class="hljs-literal">on</span> <span class="hljs-string">'data'</span>, <span class="hljs-function"><span class="hljs-params">(buffer)</span> -></span>
|
||||
buffers.push buffer <span class="hljs-keyword">if</span> buffer
|
||||
stdin.<span class="hljs-literal">on</span> <span class="hljs-string">'end'</span>, <span class="hljs-function">-></span>
|
||||
compileScript <span class="hljs-literal">null</span>, Buffer.concat(buffers).toString()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>If all of the source files are done being read, concatenate and compile
|
||||
them together.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>joinTimeout = <span class="hljs-literal">null</span>
|
||||
<span class="hljs-function"><span class="hljs-title">compileJoin</span> = -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> opts.join
|
||||
<span class="hljs-keyword">unless</span> sourceCode.some(<span class="hljs-function"><span class="hljs-params">(code)</span> -></span> code <span class="hljs-keyword">is</span> <span class="hljs-literal">null</span>)
|
||||
clearTimeout joinTimeout
|
||||
joinTimeout = wait <span class="hljs-number">100</span>, <span class="hljs-function">-></span>
|
||||
compileScript opts.join, sourceCode.join(<span class="hljs-string">'\n'</span>), opts.join</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Watch a source CoffeeScript file using <code>fs.watch</code>, recompiling it every
|
||||
time the file is updated. May be used in combination with other options,
|
||||
such as <code>--print</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">watch</span> = <span class="hljs-params">(source, base)</span> -></span>
|
||||
watcher = <span class="hljs-literal">null</span>
|
||||
prevStats = <span class="hljs-literal">null</span>
|
||||
compileTimeout = <span class="hljs-literal">null</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">watchErr</span> = <span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> source <span class="hljs-keyword">in</span> sources
|
||||
<span class="hljs-keyword">try</span>
|
||||
rewatch()
|
||||
compile()
|
||||
<span class="hljs-keyword">catch</span>
|
||||
removeSource source, base
|
||||
compileJoin()
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">compile</span> = -></span>
|
||||
clearTimeout compileTimeout
|
||||
compileTimeout = wait <span class="hljs-number">25</span>, <span class="hljs-function">-></span>
|
||||
fs.stat source, <span class="hljs-function"><span class="hljs-params">(err, stats)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> watchErr err <span class="hljs-keyword">if</span> err
|
||||
<span class="hljs-keyword">return</span> rewatch() <span class="hljs-keyword">if</span> prevStats <span class="hljs-keyword">and</span>
|
||||
stats.size <span class="hljs-keyword">is</span> prevStats.size <span class="hljs-keyword">and</span>
|
||||
stats.mtime.getTime() <span class="hljs-keyword">is</span> prevStats.mtime.getTime()
|
||||
prevStats = stats
|
||||
fs.readFile source, <span class="hljs-function"><span class="hljs-params">(err, code)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> watchErr err <span class="hljs-keyword">if</span> err
|
||||
compileScript(source, code.toString(), base)
|
||||
rewatch()
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">startWatcher</span> = -></span>
|
||||
watcher = fs.watch source
|
||||
.<span class="hljs-literal">on</span> <span class="hljs-string">'change'</span>, compile
|
||||
.<span class="hljs-literal">on</span> <span class="hljs-string">'error'</span>, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'EPERM'</span>
|
||||
removeSource source, base
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">rewatch</span> = -></span>
|
||||
watcher?.close()
|
||||
startWatcher()
|
||||
|
||||
<span class="hljs-keyword">try</span>
|
||||
startWatcher()
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
watchErr err</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Watch a directory of files for new additions.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">watchDir</span> = <span class="hljs-params">(source, base)</span> -></span>
|
||||
watcher = <span class="hljs-literal">null</span>
|
||||
readdirTimeout = <span class="hljs-literal">null</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">startWatcher</span> = -></span>
|
||||
watcher = fs.watch source
|
||||
.<span class="hljs-literal">on</span> <span class="hljs-string">'error'</span>, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'EPERM'</span>
|
||||
stopWatcher()
|
||||
.<span class="hljs-literal">on</span> <span class="hljs-string">'change'</span>, <span class="hljs-function">-></span>
|
||||
clearTimeout readdirTimeout
|
||||
readdirTimeout = wait <span class="hljs-number">25</span>, <span class="hljs-function">-></span>
|
||||
<span class="hljs-keyword">try</span>
|
||||
files = fs.readdirSync source
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-keyword">return</span> stopWatcher()
|
||||
<span class="hljs-keyword">for</span> file <span class="hljs-keyword">in</span> files
|
||||
compilePath (path.join source, file), <span class="hljs-literal">no</span>, base
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">stopWatcher</span> = -></span>
|
||||
watcher.close()
|
||||
removeSourceDir source, base
|
||||
|
||||
watchedDirs[source] = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">try</span>
|
||||
startWatcher()
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">removeSourceDir</span> = <span class="hljs-params">(source, base)</span> -></span>
|
||||
<span class="hljs-keyword">delete</span> watchedDirs[source]
|
||||
sourcesChanged = <span class="hljs-literal">no</span>
|
||||
<span class="hljs-keyword">for</span> file <span class="hljs-keyword">in</span> sources <span class="hljs-keyword">when</span> source <span class="hljs-keyword">is</span> path.dirname file
|
||||
removeSource file, base
|
||||
sourcesChanged = <span class="hljs-literal">yes</span>
|
||||
compileJoin() <span class="hljs-keyword">if</span> sourcesChanged</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>Remove a file from our source list, and source code cache. Optionally remove
|
||||
the compiled JS version as well.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">removeSource</span> = <span class="hljs-params">(source, base)</span> -></span>
|
||||
index = sources.indexOf source
|
||||
sources.splice index, <span class="hljs-number">1</span>
|
||||
sourceCode.splice index, <span class="hljs-number">1</span>
|
||||
<span class="hljs-keyword">unless</span> opts.join
|
||||
silentUnlink outputPath source, base
|
||||
silentUnlink outputPath source, base, <span class="hljs-string">'.js.map'</span>
|
||||
timeLog <span class="hljs-string">"removed <span class="hljs-subst">#{source}</span>"</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">silentUnlink</span> = <span class="hljs-params">(path)</span> -></span>
|
||||
<span class="hljs-keyword">try</span>
|
||||
fs.unlinkSync path
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">in</span> [<span class="hljs-string">'ENOENT'</span>, <span class="hljs-string">'EPERM'</span>]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>Get the corresponding output JavaScript path for a source file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">outputPath</span> = <span class="hljs-params">(source, base, extension=<span class="hljs-string">".js"</span>)</span> -></span>
|
||||
basename = helpers.baseFileName source, <span class="hljs-literal">yes</span>, useWinPathSep
|
||||
srcDir = path.dirname source
|
||||
<span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> opts.output
|
||||
dir = srcDir
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> source <span class="hljs-keyword">is</span> base
|
||||
dir = opts.output
|
||||
<span class="hljs-keyword">else</span>
|
||||
dir = path.join opts.output, path.relative base, srcDir
|
||||
path.join dir, basename + extension</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>Recursively mkdir, like <code>mkdir -p</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">mkdirp</span> = <span class="hljs-params">(dir, fn)</span> -></span>
|
||||
mode = <span class="hljs-number">0</span>o777 & ~process.umask()
|
||||
|
||||
<span class="hljs-keyword">do</span> mkdirs = <span class="hljs-function"><span class="hljs-params">(p = dir, fn)</span> -></span>
|
||||
fs.exists p, <span class="hljs-function"><span class="hljs-params">(exists)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> exists
|
||||
fn()
|
||||
<span class="hljs-keyword">else</span>
|
||||
mkdirs path.dirname(p), <span class="hljs-function">-></span>
|
||||
fs.mkdir p, mode, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> fn err <span class="hljs-keyword">if</span> err
|
||||
fn()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>Write out a JavaScript source file with the compiled code. By default, files
|
||||
are written out in <code>cwd</code> as <code>.js</code> files with the same name, but the output
|
||||
directory can be customized with <code>--output</code>.</p>
|
||||
<p>If <code>generatedSourceMap</code> is provided, this will write a <code>.js.map</code> file into the
|
||||
same directory as the <code>.js</code> file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">writeJs</span> = <span class="hljs-params">(base, sourcePath, js, jsPath, generatedSourceMap = <span class="hljs-literal">null</span>)</span> -></span>
|
||||
sourceMapPath = outputPath sourcePath, base, <span class="hljs-string">".js.map"</span>
|
||||
jsDir = path.dirname jsPath
|
||||
<span class="hljs-function"> <span class="hljs-title">compile</span> = -></span>
|
||||
<span class="hljs-keyword">if</span> opts.compile
|
||||
js = <span class="hljs-string">' '</span> <span class="hljs-keyword">if</span> js.length <= <span class="hljs-number">0</span>
|
||||
<span class="hljs-keyword">if</span> generatedSourceMap <span class="hljs-keyword">then</span> js = <span class="hljs-string">"<span class="hljs-subst">#{js}</span>\n//# sourceMappingURL=<span class="hljs-subst">#{helpers.baseFileName sourceMapPath, <span class="hljs-literal">no</span>, useWinPathSep}</span>\n"</span>
|
||||
fs.writeFile jsPath, js, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> err
|
||||
printLine err.message
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> opts.compile <span class="hljs-keyword">and</span> opts.watch
|
||||
timeLog <span class="hljs-string">"compiled <span class="hljs-subst">#{sourcePath}</span>"</span>
|
||||
<span class="hljs-keyword">if</span> generatedSourceMap
|
||||
fs.writeFile sourceMapPath, generatedSourceMap, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> err
|
||||
printLine <span class="hljs-string">"Could not write source map: <span class="hljs-subst">#{err.message}</span>"</span>
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
fs.exists jsDir, <span class="hljs-function"><span class="hljs-params">(itExists)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> itExists <span class="hljs-keyword">then</span> compile() <span class="hljs-keyword">else</span> mkdirp jsDir, compile</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Convenience for cleaner setTimeouts.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">wait</span> = <span class="hljs-params">(milliseconds, func)</span> -></span> setTimeout func, milliseconds</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<p>When watching scripts, it’s useful to log changes with the timestamp.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">timeLog</span> = <span class="hljs-params">(message)</span> -></span>
|
||||
<span class="hljs-built_in">console</span>.log <span class="hljs-string">"<span class="hljs-subst">#{(<span class="hljs-keyword">new</span> Date).toLocaleTimeString()}</span> - <span class="hljs-subst">#{message}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
<p>Pretty-print a stream of tokens, sans location data.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">printTokens</span> = <span class="hljs-params">(tokens)</span> -></span>
|
||||
strings = <span class="hljs-keyword">for</span> token <span class="hljs-keyword">in</span> tokens
|
||||
tag = token[<span class="hljs-number">0</span>]
|
||||
value = token[<span class="hljs-number">1</span>].toString().replace(<span class="hljs-regexp">/\n/</span>, <span class="hljs-string">'\\n'</span>)
|
||||
<span class="hljs-string">"[<span class="hljs-subst">#{tag}</span> <span class="hljs-subst">#{value}</span>]"</span>
|
||||
printLine strings.join(<span class="hljs-string">' '</span>)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>Use the <a href="optparse.html">OptionParser module</a> to extract all options from
|
||||
<code>process.argv</code> that are specified in <code>SWITCHES</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">parseOptions</span> = -></span>
|
||||
optionParser = <span class="hljs-keyword">new</span> optparse.OptionParser SWITCHES, BANNER
|
||||
o = opts = optionParser.parse process.argv[<span class="hljs-number">2.</span>.]
|
||||
o.compile <span class="hljs-keyword">or</span>= !!o.output
|
||||
o.run = <span class="hljs-keyword">not</span> (o.compile <span class="hljs-keyword">or</span> o.<span class="hljs-built_in">print</span> <span class="hljs-keyword">or</span> o.map)
|
||||
o.<span class="hljs-built_in">print</span> = !! (o.<span class="hljs-built_in">print</span> <span class="hljs-keyword">or</span> (o.eval <span class="hljs-keyword">or</span> o.stdio <span class="hljs-keyword">and</span> o.compile))</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-23">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-23">¶</a>
|
||||
</div>
|
||||
<p>The compile-time options to pass to the CoffeeScript compiler.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">compileOptions</span> = <span class="hljs-params">(filename, base)</span> -></span>
|
||||
answer = {
|
||||
filename
|
||||
literate: opts.literate <span class="hljs-keyword">or</span> helpers.isLiterate(filename)
|
||||
bare: opts.bare
|
||||
header: opts.compile <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> opts[<span class="hljs-string">'no-header'</span>]
|
||||
sourceMap: opts.map
|
||||
inlineMap: opts[<span class="hljs-string">'inline-map'</span>]
|
||||
}
|
||||
<span class="hljs-keyword">if</span> filename
|
||||
<span class="hljs-keyword">if</span> base
|
||||
cwd = process.cwd()
|
||||
jsPath = outputPath filename, base
|
||||
jsDir = path.dirname jsPath
|
||||
answer = helpers.merge answer, {
|
||||
jsPath
|
||||
sourceRoot: path.relative jsDir, cwd
|
||||
sourceFiles: [path.relative cwd, filename]
|
||||
generatedFile: helpers.baseFileName(jsPath, <span class="hljs-literal">no</span>, useWinPathSep)
|
||||
}
|
||||
<span class="hljs-keyword">else</span>
|
||||
answer = helpers.merge answer,
|
||||
sourceRoot: <span class="hljs-string">""</span>
|
||||
sourceFiles: [helpers.baseFileName filename, <span class="hljs-literal">no</span>, useWinPathSep]
|
||||
generatedFile: helpers.baseFileName(filename, <span class="hljs-literal">yes</span>, useWinPathSep) + <span class="hljs-string">".js"</span>
|
||||
answer</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-24">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-24">¶</a>
|
||||
</div>
|
||||
<p>Start up a new Node.js instance with the arguments in <code>--nodejs</code> passed to
|
||||
the <code>node</code> binary, preserving the other options.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">forkNode</span> = -></span>
|
||||
nodeArgs = opts.nodejs.split <span class="hljs-regexp">/\s+/</span>
|
||||
args = process.argv[<span class="hljs-number">1.</span>.]
|
||||
args.splice args.indexOf(<span class="hljs-string">'--nodejs'</span>), <span class="hljs-number">2</span>
|
||||
p = spawn process.execPath, nodeArgs.concat(args),
|
||||
cwd: process.cwd()
|
||||
env: process.env
|
||||
stdio: [<span class="hljs-number">0</span>, <span class="hljs-number">1</span>, <span class="hljs-number">2</span>]
|
||||
p.<span class="hljs-literal">on</span> <span class="hljs-string">'exit'</span>, <span class="hljs-function"><span class="hljs-params">(code)</span> -></span> process.exit code</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-25">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-25">¶</a>
|
||||
</div>
|
||||
<p>Print the <code>--help</code> usage message and exit. Deprecated switches are not
|
||||
shown.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">usage</span> = -></span>
|
||||
printLine (<span class="hljs-keyword">new</span> optparse.OptionParser SWITCHES, BANNER).help()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-26">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-26">¶</a>
|
||||
</div>
|
||||
<p>Print the <code>--version</code> message and exit.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">version</span> = -></span>
|
||||
printLine <span class="hljs-string">"CoffeeScript version <span class="hljs-subst">#{CoffeeScript.VERSION}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
518
docs/v1/annotated-source/docco.css
Normal file
@@ -0,0 +1,518 @@
|
||||
/*--------------------- Typography ----------------------------*/
|
||||
|
||||
@font-face {
|
||||
font-family: 'aller-light';
|
||||
src: url('public/fonts/aller-light.eot');
|
||||
src: url('public/fonts/aller-light.eot?#iefix') format('embedded-opentype'),
|
||||
url('public/fonts/aller-light.woff') format('woff'),
|
||||
url('public/fonts/aller-light.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'aller-bold';
|
||||
src: url('public/fonts/aller-bold.eot');
|
||||
src: url('public/fonts/aller-bold.eot?#iefix') format('embedded-opentype'),
|
||||
url('public/fonts/aller-bold.woff') format('woff'),
|
||||
url('public/fonts/aller-bold.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'roboto-black';
|
||||
src: url('public/fonts/roboto-black.eot');
|
||||
src: url('public/fonts/roboto-black.eot?#iefix') format('embedded-opentype'),
|
||||
url('public/fonts/roboto-black.woff') format('woff'),
|
||||
url('public/fonts/roboto-black.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
/*--------------------- Layout ----------------------------*/
|
||||
html { height: 100%; }
|
||||
body {
|
||||
font-family: "aller-light";
|
||||
font-size: 14px;
|
||||
line-height: 18px;
|
||||
color: #30404f;
|
||||
margin: 0; padding: 0;
|
||||
height:100%;
|
||||
}
|
||||
#container { min-height: 100%; }
|
||||
|
||||
a {
|
||||
color: #000;
|
||||
}
|
||||
|
||||
b, strong {
|
||||
font-weight: normal;
|
||||
font-family: "aller-bold";
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 15px 0 0px;
|
||||
}
|
||||
.annotation ul, .annotation ol {
|
||||
margin: 25px 0;
|
||||
}
|
||||
.annotation ul li, .annotation ol li {
|
||||
font-size: 14px;
|
||||
line-height: 18px;
|
||||
margin: 10px 0;
|
||||
}
|
||||
|
||||
h1, h2, h3, h4, h5, h6 {
|
||||
color: #112233;
|
||||
line-height: 1em;
|
||||
font-weight: normal;
|
||||
font-family: "roboto-black";
|
||||
text-transform: uppercase;
|
||||
margin: 30px 0 15px 0;
|
||||
}
|
||||
|
||||
h1 {
|
||||
margin-top: 40px;
|
||||
}
|
||||
h2 {
|
||||
font-size: 1.26em;
|
||||
}
|
||||
|
||||
hr {
|
||||
border: 0;
|
||||
background: 1px #ddd;
|
||||
height: 1px;
|
||||
margin: 20px 0;
|
||||
}
|
||||
|
||||
pre, tt, code {
|
||||
font-size: 12px; line-height: 16px;
|
||||
font-family: Menlo, Monaco, Consolas, "Lucida Console", monospace;
|
||||
margin: 0; padding: 0;
|
||||
}
|
||||
.annotation pre {
|
||||
display: block;
|
||||
margin: 0;
|
||||
padding: 7px 10px;
|
||||
background: #fcfcfc;
|
||||
-moz-box-shadow: inset 0 0 10px rgba(0,0,0,0.1);
|
||||
-webkit-box-shadow: inset 0 0 10px rgba(0,0,0,0.1);
|
||||
box-shadow: inset 0 0 10px rgba(0,0,0,0.1);
|
||||
overflow-x: auto;
|
||||
}
|
||||
.annotation pre code {
|
||||
border: 0;
|
||||
padding: 0;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
|
||||
blockquote {
|
||||
border-left: 5px solid #ccc;
|
||||
margin: 0;
|
||||
padding: 1px 0 1px 1em;
|
||||
}
|
||||
.sections blockquote p {
|
||||
font-family: Menlo, Consolas, Monaco, monospace;
|
||||
font-size: 12px; line-height: 16px;
|
||||
color: #999;
|
||||
margin: 10px 0 0;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
ul.sections {
|
||||
list-style: none;
|
||||
padding:0 0 5px 0;;
|
||||
margin:0;
|
||||
}
|
||||
|
||||
/*
|
||||
Force border-box so that % widths fit the parent
|
||||
container without overlap because of margin/padding.
|
||||
|
||||
More Info : http://www.quirksmode.org/css/box.html
|
||||
*/
|
||||
ul.sections > li > div {
|
||||
-moz-box-sizing: border-box; /* firefox */
|
||||
-ms-box-sizing: border-box; /* ie */
|
||||
-webkit-box-sizing: border-box; /* webkit */
|
||||
-khtml-box-sizing: border-box; /* konqueror */
|
||||
box-sizing: border-box; /* css3 */
|
||||
}
|
||||
|
||||
|
||||
/*---------------------- Jump Page -----------------------------*/
|
||||
#jump_to, #jump_page {
|
||||
margin: 0;
|
||||
background: white;
|
||||
-webkit-box-shadow: 0 0 25px #777; -moz-box-shadow: 0 0 25px #777;
|
||||
-webkit-border-bottom-left-radius: 5px; -moz-border-radius-bottomleft: 5px;
|
||||
font: 16px Arial;
|
||||
cursor: pointer;
|
||||
text-align: right;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
#jump_to a {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
#jump_to a.large {
|
||||
display: none;
|
||||
}
|
||||
#jump_to a.small {
|
||||
font-size: 22px;
|
||||
font-weight: bold;
|
||||
color: #676767;
|
||||
}
|
||||
|
||||
#jump_to, #jump_wrapper {
|
||||
position: fixed;
|
||||
right: 0; top: 0;
|
||||
padding: 10px 15px;
|
||||
margin:0;
|
||||
}
|
||||
|
||||
#jump_wrapper {
|
||||
display: none;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
#jump_to:hover #jump_wrapper {
|
||||
display: block;
|
||||
}
|
||||
|
||||
#jump_page_wrapper{
|
||||
position: fixed;
|
||||
right: 0;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
}
|
||||
|
||||
#jump_page {
|
||||
padding: 5px 0 3px;
|
||||
margin: 0 0 25px 25px;
|
||||
max-height: 100%;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
#jump_page .source {
|
||||
display: block;
|
||||
padding: 15px;
|
||||
text-decoration: none;
|
||||
border-top: 1px solid #eee;
|
||||
}
|
||||
|
||||
#jump_page .source:hover {
|
||||
background: #f5f5ff;
|
||||
}
|
||||
|
||||
#jump_page .source:first-child {
|
||||
}
|
||||
|
||||
/*---------------------- Low resolutions (> 320px) ---------------------*/
|
||||
@media only screen and (min-width: 320px) {
|
||||
.pilwrap { display: none; }
|
||||
|
||||
ul.sections > li > div {
|
||||
display: block;
|
||||
padding:5px 10px 0 10px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation ul, ul.sections > li > div.annotation ol {
|
||||
padding-left: 30px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.content {
|
||||
overflow-x:auto;
|
||||
-webkit-box-shadow: inset 0 0 5px #e5e5ee;
|
||||
box-shadow: inset 0 0 5px #e5e5ee;
|
||||
border: 1px solid #dedede;
|
||||
margin:5px 10px 5px 10px;
|
||||
padding-bottom: 5px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation pre {
|
||||
margin: 7px 0 7px;
|
||||
padding-left: 15px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation p tt, .annotation code {
|
||||
background: #f8f8ff;
|
||||
border: 1px solid #dedede;
|
||||
font-size: 12px;
|
||||
padding: 0 0.2em;
|
||||
}
|
||||
}
|
||||
|
||||
/*---------------------- (> 481px) ---------------------*/
|
||||
@media only screen and (min-width: 481px) {
|
||||
#container {
|
||||
position: relative;
|
||||
}
|
||||
body {
|
||||
background-color: #F5F5FF;
|
||||
font-size: 15px;
|
||||
line-height: 21px;
|
||||
}
|
||||
pre, tt, code {
|
||||
line-height: 18px;
|
||||
}
|
||||
p, ul, ol {
|
||||
margin: 0 0 15px;
|
||||
}
|
||||
|
||||
|
||||
#jump_to {
|
||||
padding: 5px 10px;
|
||||
}
|
||||
#jump_wrapper {
|
||||
padding: 0;
|
||||
}
|
||||
#jump_to, #jump_page {
|
||||
font: 10px Arial;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
#jump_page .source {
|
||||
padding: 5px 10px;
|
||||
}
|
||||
#jump_to a.large {
|
||||
display: inline-block;
|
||||
}
|
||||
#jump_to a.small {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#background {
|
||||
position: absolute;
|
||||
top: 0; bottom: 0;
|
||||
width: 350px;
|
||||
background: #fff;
|
||||
border-right: 1px solid #e5e5ee;
|
||||
z-index: -1;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation ul, ul.sections > li > div.annotation ol {
|
||||
padding-left: 40px;
|
||||
}
|
||||
|
||||
ul.sections > li {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
ul.sections > li > div {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation {
|
||||
max-width: 350px;
|
||||
min-width: 350px;
|
||||
min-height: 5px;
|
||||
padding: 13px;
|
||||
overflow-x: hidden;
|
||||
white-space: normal;
|
||||
vertical-align: top;
|
||||
text-align: left;
|
||||
}
|
||||
ul.sections > li > div.annotation pre {
|
||||
margin: 15px 0 15px;
|
||||
padding-left: 15px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.content {
|
||||
padding: 13px;
|
||||
vertical-align: top;
|
||||
border: none;
|
||||
-webkit-box-shadow: none;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.pilwrap {
|
||||
position: relative;
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.pilcrow {
|
||||
font: 12px Arial;
|
||||
text-decoration: none;
|
||||
color: #454545;
|
||||
position: absolute;
|
||||
top: 3px; left: -20px;
|
||||
padding: 1px 2px;
|
||||
opacity: 0;
|
||||
-webkit-transition: opacity 0.2s linear;
|
||||
}
|
||||
.for-h1 .pilcrow {
|
||||
top: 47px;
|
||||
}
|
||||
.for-h2 .pilcrow, .for-h3 .pilcrow, .for-h4 .pilcrow {
|
||||
top: 35px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation:hover .pilcrow {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
/*---------------------- (> 1025px) ---------------------*/
|
||||
@media only screen and (min-width: 1025px) {
|
||||
|
||||
body {
|
||||
font-size: 16px;
|
||||
line-height: 24px;
|
||||
}
|
||||
|
||||
#background {
|
||||
width: 525px;
|
||||
}
|
||||
ul.sections > li > div.annotation {
|
||||
max-width: 525px;
|
||||
min-width: 525px;
|
||||
padding: 10px 25px 1px 50px;
|
||||
}
|
||||
ul.sections > li > div.content {
|
||||
padding: 9px 15px 16px 25px;
|
||||
}
|
||||
}
|
||||
|
||||
/*---------------------- Syntax Highlighting -----------------------------*/
|
||||
|
||||
td.linenos { background-color: #f0f0f0; padding-right: 10px; }
|
||||
span.lineno { background-color: #f0f0f0; padding: 0 5px 0 5px; }
|
||||
/*
|
||||
|
||||
github.com style (c) Vasily Polovnyov <vast@whiteants.net>
|
||||
|
||||
*/
|
||||
|
||||
pre code {
|
||||
display: block; padding: 0.5em;
|
||||
color: #000;
|
||||
background: #f8f8ff
|
||||
}
|
||||
|
||||
pre .hljs-comment,
|
||||
pre .hljs-template_comment,
|
||||
pre .hljs-diff .hljs-header,
|
||||
pre .hljs-javadoc {
|
||||
color: #408080;
|
||||
font-style: italic
|
||||
}
|
||||
|
||||
pre .hljs-keyword,
|
||||
pre .hljs-assignment,
|
||||
pre .hljs-literal,
|
||||
pre .hljs-css .hljs-rule .hljs-keyword,
|
||||
pre .hljs-winutils,
|
||||
pre .hljs-javascript .hljs-title,
|
||||
pre .hljs-lisp .hljs-title,
|
||||
pre .hljs-subst {
|
||||
color: #954121;
|
||||
/*font-weight: bold*/
|
||||
}
|
||||
|
||||
pre .hljs-number,
|
||||
pre .hljs-hexcolor {
|
||||
color: #40a070
|
||||
}
|
||||
|
||||
pre .hljs-string,
|
||||
pre .hljs-tag .hljs-value,
|
||||
pre .hljs-phpdoc,
|
||||
pre .hljs-tex .hljs-formula {
|
||||
color: #219161;
|
||||
}
|
||||
|
||||
pre .hljs-title,
|
||||
pre .hljs-id {
|
||||
color: #19469D;
|
||||
}
|
||||
pre .hljs-params {
|
||||
color: #00F;
|
||||
}
|
||||
|
||||
pre .hljs-javascript .hljs-title,
|
||||
pre .hljs-lisp .hljs-title,
|
||||
pre .hljs-subst {
|
||||
font-weight: normal
|
||||
}
|
||||
|
||||
pre .hljs-class .hljs-title,
|
||||
pre .hljs-haskell .hljs-label,
|
||||
pre .hljs-tex .hljs-command {
|
||||
color: #458;
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
pre .hljs-tag,
|
||||
pre .hljs-tag .hljs-title,
|
||||
pre .hljs-rules .hljs-property,
|
||||
pre .hljs-django .hljs-tag .hljs-keyword {
|
||||
color: #000080;
|
||||
font-weight: normal
|
||||
}
|
||||
|
||||
pre .hljs-attribute,
|
||||
pre .hljs-variable,
|
||||
pre .hljs-instancevar,
|
||||
pre .hljs-lisp .hljs-body {
|
||||
color: #008080
|
||||
}
|
||||
|
||||
pre .hljs-regexp {
|
||||
color: #B68
|
||||
}
|
||||
|
||||
pre .hljs-class {
|
||||
color: #458;
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
pre .hljs-symbol,
|
||||
pre .hljs-ruby .hljs-symbol .hljs-string,
|
||||
pre .hljs-ruby .hljs-symbol .hljs-keyword,
|
||||
pre .hljs-ruby .hljs-symbol .hljs-keymethods,
|
||||
pre .hljs-lisp .hljs-keyword,
|
||||
pre .hljs-tex .hljs-special,
|
||||
pre .hljs-input_number {
|
||||
color: #990073
|
||||
}
|
||||
|
||||
pre .hljs-builtin,
|
||||
pre .hljs-constructor,
|
||||
pre .hljs-built_in,
|
||||
pre .hljs-lisp .hljs-title {
|
||||
color: #0086b3
|
||||
}
|
||||
|
||||
pre .hljs-preprocessor,
|
||||
pre .hljs-pi,
|
||||
pre .hljs-doctype,
|
||||
pre .hljs-shebang,
|
||||
pre .hljs-cdata {
|
||||
color: #999;
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
pre .hljs-deletion {
|
||||
background: #fdd
|
||||
}
|
||||
|
||||
pre .hljs-addition {
|
||||
background: #dfd
|
||||
}
|
||||
|
||||
pre .hljs-diff .hljs-change {
|
||||
background: #0086b3
|
||||
}
|
||||
|
||||
pre .hljs-chunk {
|
||||
color: #aaa
|
||||
}
|
||||
|
||||
pre .hljs-tex .hljs-formula {
|
||||
opacity: 0.5;
|
||||
}
|
||||
1716
docs/v1/annotated-source/grammar.html
Normal file
612
docs/v1/annotated-source/helpers.html
Normal file
@@ -0,0 +1,612 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>helpers.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>helpers.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>This file contains the common helper functions that we’d like to share among
|
||||
the <strong>Lexer</strong>, <strong>Rewriter</strong>, and the <strong>Nodes</strong>. Merge objects, flatten
|
||||
arrays, count characters, that sort of thing.</p>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Peek at the beginning of a given string to see if it matches a sequence.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.starts = <span class="hljs-function"><span class="hljs-params">(string, literal, start)</span> -></span>
|
||||
literal <span class="hljs-keyword">is</span> string.substr start, literal.length</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Peek at the end of a given string to see if it matches a sequence.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.ends = <span class="hljs-function"><span class="hljs-params">(string, literal, back)</span> -></span>
|
||||
len = literal.length
|
||||
literal <span class="hljs-keyword">is</span> string.substr string.length - len - (back <span class="hljs-keyword">or</span> <span class="hljs-number">0</span>), len</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Repeat a string <code>n</code> times.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.repeat = repeat = <span class="hljs-function"><span class="hljs-params">(str, n)</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Use clever algorithm to have O(log(n)) string concatenation operations.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> res = <span class="hljs-string">''</span>
|
||||
<span class="hljs-keyword">while</span> n > <span class="hljs-number">0</span>
|
||||
res += str <span class="hljs-keyword">if</span> n & <span class="hljs-number">1</span>
|
||||
n >>>= <span class="hljs-number">1</span>
|
||||
str += str
|
||||
res</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Trim out all falsy values from an array.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.compact = <span class="hljs-function"><span class="hljs-params">(array)</span> -></span>
|
||||
item <span class="hljs-keyword">for</span> item <span class="hljs-keyword">in</span> array <span class="hljs-keyword">when</span> item</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Count the number of occurrences of a string in a string.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.count = <span class="hljs-function"><span class="hljs-params">(string, substr)</span> -></span>
|
||||
num = pos = <span class="hljs-number">0</span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-number">1</span>/<span class="hljs-number">0</span> <span class="hljs-keyword">unless</span> substr.length
|
||||
num++ <span class="hljs-keyword">while</span> pos = <span class="hljs-number">1</span> + string.indexOf substr, pos
|
||||
num</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Merge objects, returning a fresh copy with attributes from both sides.
|
||||
Used every time <code>Base#compile</code> is called, to allow properties in the
|
||||
options hash to propagate down the tree without polluting other branches.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.merge = <span class="hljs-function"><span class="hljs-params">(options, overrides)</span> -></span>
|
||||
extend (extend {}, options), overrides</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Extend a source object with the properties of another object (shallow copy).</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>extend = exports.extend = <span class="hljs-function"><span class="hljs-params">(object, properties)</span> -></span>
|
||||
<span class="hljs-keyword">for</span> key, val <span class="hljs-keyword">of</span> properties
|
||||
object[key] = val
|
||||
object</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Return a flattened version of an array.
|
||||
Handy for getting a list of <code>children</code> from the nodes.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.flatten = flatten = <span class="hljs-function"><span class="hljs-params">(array)</span> -></span>
|
||||
flattened = []
|
||||
<span class="hljs-keyword">for</span> element <span class="hljs-keyword">in</span> array
|
||||
<span class="hljs-keyword">if</span> <span class="hljs-string">'[object Array]'</span> <span class="hljs-keyword">is</span> Object::toString.call element
|
||||
flattened = flattened.concat flatten element
|
||||
<span class="hljs-keyword">else</span>
|
||||
flattened.push element
|
||||
flattened</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Delete a key from an object, returning the value. Useful when a node is
|
||||
looking for a particular method in an options hash.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.del = <span class="hljs-function"><span class="hljs-params">(obj, key)</span> -></span>
|
||||
val = obj[key]
|
||||
<span class="hljs-keyword">delete</span> obj[key]
|
||||
val</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Typical Array::some</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.some = Array::some ? (fn) ->
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-literal">true</span> <span class="hljs-keyword">for</span> e <span class="hljs-keyword">in</span> <span class="hljs-keyword">this</span> <span class="hljs-keyword">when</span> fn e
|
||||
<span class="hljs-literal">false</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Simple function for inverting Literate CoffeeScript code by putting the
|
||||
documentation in comments, producing a string of CoffeeScript code that
|
||||
can be compiled “normally”.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.invertLiterate = <span class="hljs-function"><span class="hljs-params">(code)</span> -></span>
|
||||
maybe_code = <span class="hljs-literal">true</span>
|
||||
lines = <span class="hljs-keyword">for</span> line <span class="hljs-keyword">in</span> code.split(<span class="hljs-string">'\n'</span>)
|
||||
<span class="hljs-keyword">if</span> maybe_code <span class="hljs-keyword">and</span> <span class="hljs-regexp">/^([ ]{4}|[ ]{0,3}\t)/</span>.test line
|
||||
line
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> maybe_code = <span class="hljs-regexp">/^\s*$/</span>.test line
|
||||
line
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">'# '</span> + line
|
||||
lines.join <span class="hljs-string">'\n'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Merge two jison-style location data objects together.
|
||||
If <code>last</code> is not provided, this will simply return <code>first</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">buildLocationData</span> = <span class="hljs-params">(first, last)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> last
|
||||
first
|
||||
<span class="hljs-keyword">else</span>
|
||||
first_line: first.first_line
|
||||
first_column: first.first_column
|
||||
last_line: last.last_line
|
||||
last_column: last.last_column</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>This returns a function which takes an object as a parameter, and if that
|
||||
object is an AST node, updates that object’s locationData.
|
||||
The object is returned either way.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.addLocationDataFn = <span class="hljs-function"><span class="hljs-params">(first, last)</span> -></span>
|
||||
(obj) ->
|
||||
<span class="hljs-keyword">if</span> ((<span class="hljs-keyword">typeof</span> obj) <span class="hljs-keyword">is</span> <span class="hljs-string">'object'</span>) <span class="hljs-keyword">and</span> (!!obj[<span class="hljs-string">'updateLocationDataIfMissing'</span>])
|
||||
obj.updateLocationDataIfMissing buildLocationData(first, last)
|
||||
|
||||
<span class="hljs-keyword">return</span> obj</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>Convert jison location data to a string.
|
||||
<code>obj</code> can be a token, or a locationData.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.locationDataToString = <span class="hljs-function"><span class="hljs-params">(obj)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> (<span class="hljs-string">"2"</span> <span class="hljs-keyword">of</span> obj) <span class="hljs-keyword">and</span> (<span class="hljs-string">"first_line"</span> <span class="hljs-keyword">of</span> obj[<span class="hljs-number">2</span>]) <span class="hljs-keyword">then</span> locationData = obj[<span class="hljs-number">2</span>]
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> <span class="hljs-string">"first_line"</span> <span class="hljs-keyword">of</span> obj <span class="hljs-keyword">then</span> locationData = obj
|
||||
|
||||
<span class="hljs-keyword">if</span> locationData
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{locationData.first_line + <span class="hljs-number">1</span>}</span>:<span class="hljs-subst">#{locationData.first_column + <span class="hljs-number">1</span>}</span>-"</span> +
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{locationData.last_line + <span class="hljs-number">1</span>}</span>:<span class="hljs-subst">#{locationData.last_column + <span class="hljs-number">1</span>}</span>"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">"No location data"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>A <code>.coffee.md</code> compatible version of <code>basename</code>, that returns the file sans-extension.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.baseFileName = <span class="hljs-function"><span class="hljs-params">(file, stripExt = <span class="hljs-literal">no</span>, useWinPathSep = <span class="hljs-literal">no</span>)</span> -></span>
|
||||
pathSep = <span class="hljs-keyword">if</span> useWinPathSep <span class="hljs-keyword">then</span> <span class="hljs-regexp">/\\|\//</span> <span class="hljs-keyword">else</span> <span class="hljs-regexp">/\//</span>
|
||||
parts = file.split(pathSep)
|
||||
file = parts[parts.length - <span class="hljs-number">1</span>]
|
||||
<span class="hljs-keyword">return</span> file <span class="hljs-keyword">unless</span> stripExt <span class="hljs-keyword">and</span> file.indexOf(<span class="hljs-string">'.'</span>) >= <span class="hljs-number">0</span>
|
||||
parts = file.split(<span class="hljs-string">'.'</span>)
|
||||
parts.pop()
|
||||
parts.pop() <span class="hljs-keyword">if</span> parts[parts.length - <span class="hljs-number">1</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">'coffee'</span> <span class="hljs-keyword">and</span> parts.length > <span class="hljs-number">1</span>
|
||||
parts.join(<span class="hljs-string">'.'</span>)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>Determine if a filename represents a CoffeeScript file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.isCoffee = <span class="hljs-function"><span class="hljs-params">(file)</span> -></span> <span class="hljs-regexp">/\.((lit)?coffee|coffee\.md)$/</span>.test file</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Determine if a filename represents a Literate CoffeeScript file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.isLiterate = <span class="hljs-function"><span class="hljs-params">(file)</span> -></span> <span class="hljs-regexp">/\.(litcoffee|coffee\.md)$/</span>.test file</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<p>Throws a SyntaxError from a given location.
|
||||
The error’s <code>toString</code> will return an error message following the “standard”
|
||||
format <code><filename>:<line>:<col>: <message></code> plus the line with the error and a
|
||||
marker showing where the error is.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.throwSyntaxError = <span class="hljs-function"><span class="hljs-params">(message, location)</span> -></span>
|
||||
error = <span class="hljs-keyword">new</span> SyntaxError message
|
||||
error.location = location
|
||||
error.toString = syntaxErrorToString</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
<p>Instead of showing the compiler’s stacktrace, show our custom error message
|
||||
(this is useful when the error bubbles up in Node.js applications that
|
||||
compile CoffeeScript for example).</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> error.stack = error.toString()
|
||||
|
||||
<span class="hljs-keyword">throw</span> error</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>Update a compiler SyntaxError with source code information if it didn’t have
|
||||
it already.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.updateSyntaxError = <span class="hljs-function"><span class="hljs-params">(error, code, filename)</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-23">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-23">¶</a>
|
||||
</div>
|
||||
<p>Avoid screwing up the <code>stack</code> property of other errors (i.e. possible bugs).</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> error.toString <span class="hljs-keyword">is</span> syntaxErrorToString
|
||||
error.code <span class="hljs-keyword">or</span>= code
|
||||
error.filename <span class="hljs-keyword">or</span>= filename
|
||||
error.stack = error.toString()
|
||||
error
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">syntaxErrorToString</span> = -></span>
|
||||
<span class="hljs-keyword">return</span> Error::toString.call @ <span class="hljs-keyword">unless</span> @code <span class="hljs-keyword">and</span> @location
|
||||
|
||||
{first_line, first_column, last_line, last_column} = @location
|
||||
last_line ?= first_line
|
||||
last_column ?= first_column
|
||||
|
||||
filename = @filename <span class="hljs-keyword">or</span> <span class="hljs-string">'[stdin]'</span>
|
||||
codeLine = @code.split(<span class="hljs-string">'\n'</span>)[first_line]
|
||||
start = first_column</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-24">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-24">¶</a>
|
||||
</div>
|
||||
<p>Show only the first line on multi-line errors.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> end = <span class="hljs-keyword">if</span> first_line <span class="hljs-keyword">is</span> last_line <span class="hljs-keyword">then</span> last_column + <span class="hljs-number">1</span> <span class="hljs-keyword">else</span> codeLine.length
|
||||
marker = codeLine[...start].replace(<span class="hljs-regexp">/[^\s]/g</span>, <span class="hljs-string">' '</span>) + repeat(<span class="hljs-string">'^'</span>, end - start)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-25">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-25">¶</a>
|
||||
</div>
|
||||
<p>Check to see if we’re running on a color-enabled TTY.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> process?
|
||||
colorsEnabled = process.stdout?.isTTY <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> process.env?.NODE_DISABLE_COLORS
|
||||
|
||||
<span class="hljs-keyword">if</span> @colorful ? colorsEnabled
|
||||
<span class="hljs-function"> <span class="hljs-title">colorize</span> = <span class="hljs-params">(str)</span> -></span> <span class="hljs-string">"\x1B[1;31m<span class="hljs-subst">#{str}</span>\x1B[0m"</span>
|
||||
codeLine = codeLine[...start] + colorize(codeLine[start...end]) + codeLine[end..]
|
||||
marker = colorize marker
|
||||
|
||||
<span class="hljs-string">"""
|
||||
<span class="hljs-subst">#{filename}</span>:<span class="hljs-subst">#{first_line + <span class="hljs-number">1</span>}</span>:<span class="hljs-subst">#{first_column + <span class="hljs-number">1</span>}</span>: error: <span class="hljs-subst">#{@message}</span>
|
||||
<span class="hljs-subst">#{codeLine}</span>
|
||||
<span class="hljs-subst">#{marker}</span>
|
||||
"""</span>
|
||||
|
||||
exports.nameWhitespaceCharacter = <span class="hljs-function"><span class="hljs-params">(string)</span> -></span>
|
||||
<span class="hljs-keyword">switch</span> string
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-string">' '</span> <span class="hljs-keyword">then</span> <span class="hljs-string">'space'</span>
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-string">'\n'</span> <span class="hljs-keyword">then</span> <span class="hljs-string">'newline'</span>
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-string">'\r'</span> <span class="hljs-keyword">then</span> <span class="hljs-string">'carriage return'</span>
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-string">'\t'</span> <span class="hljs-keyword">then</span> <span class="hljs-string">'tab'</span>
|
||||
<span class="hljs-keyword">else</span> string</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
129
docs/v1/annotated-source/index.html
Normal file
@@ -0,0 +1,129 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>index.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>index.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>Loader for CoffeeScript as a Node.js library.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports[key] = val <span class="hljs-keyword">for</span> key, val <span class="hljs-keyword">of</span> <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffee-script'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
2261
docs/v1/annotated-source/lexer.html
Normal file
5208
docs/v1/annotated-source/nodes.html
Normal file
366
docs/v1/annotated-source/optparse.html
Normal file
@@ -0,0 +1,366 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>optparse.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>optparse.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>{repeat} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>A simple <strong>OptionParser</strong> class to parse option flags from the command-line.
|
||||
Use it like so:</p>
|
||||
<pre><code>parser = <span class="hljs-keyword">new</span> OptionParser switches, helpBanner
|
||||
options = parser.parse process.argv
|
||||
</code></pre><p>The first non-option is considered to be the start of the file (and file
|
||||
option) list, and all subsequent arguments are left unparsed.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.OptionParser = <span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">OptionParser</span></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Initialize with a list of valid options, in the form:</p>
|
||||
<pre><code>[short-flag, long-flag, description]
|
||||
</code></pre><p>Along with an optional banner for the usage help.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> constructor: <span class="hljs-function"><span class="hljs-params">(rules, @banner)</span> -></span>
|
||||
@rules = buildRules rules</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Parse the list of arguments, populating an <code>options</code> object with all of the
|
||||
specified options, and return it. Options after the first non-option
|
||||
argument are treated as arguments. <code>options.arguments</code> will be an array
|
||||
containing the remaining arguments. This is a simpler API than many option
|
||||
parsers that allow you to attach callback actions for every flag. Instead,
|
||||
you’re responsible for interpreting the options object.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> parse: <span class="hljs-function"><span class="hljs-params">(args)</span> -></span>
|
||||
options = arguments: []
|
||||
skippingArgument = <span class="hljs-literal">no</span>
|
||||
originalArgs = args
|
||||
args = normalizeArguments args
|
||||
<span class="hljs-keyword">for</span> arg, i <span class="hljs-keyword">in</span> args
|
||||
<span class="hljs-keyword">if</span> skippingArgument
|
||||
skippingArgument = <span class="hljs-literal">no</span>
|
||||
<span class="hljs-keyword">continue</span>
|
||||
<span class="hljs-keyword">if</span> arg <span class="hljs-keyword">is</span> <span class="hljs-string">'--'</span>
|
||||
pos = originalArgs.indexOf <span class="hljs-string">'--'</span>
|
||||
options.arguments = options.arguments.concat originalArgs[(pos + <span class="hljs-number">1</span>)..]
|
||||
<span class="hljs-keyword">break</span>
|
||||
isOption = !!(arg.match(LONG_FLAG) <span class="hljs-keyword">or</span> arg.match(SHORT_FLAG))</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>the CS option parser is a little odd; options after the first
|
||||
non-option argument are treated as non-option arguments themselves</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> seenNonOptionArg = options.arguments.length > <span class="hljs-number">0</span>
|
||||
<span class="hljs-keyword">unless</span> seenNonOptionArg
|
||||
matchedRule = <span class="hljs-literal">no</span>
|
||||
<span class="hljs-keyword">for</span> rule <span class="hljs-keyword">in</span> @rules
|
||||
<span class="hljs-keyword">if</span> rule.shortFlag <span class="hljs-keyword">is</span> arg <span class="hljs-keyword">or</span> rule.longFlag <span class="hljs-keyword">is</span> arg
|
||||
value = <span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">if</span> rule.hasArgument
|
||||
skippingArgument = <span class="hljs-literal">yes</span>
|
||||
value = args[i + <span class="hljs-number">1</span>]
|
||||
options[rule.name] = <span class="hljs-keyword">if</span> rule.isList <span class="hljs-keyword">then</span> (options[rule.name] <span class="hljs-keyword">or</span> []).concat value <span class="hljs-keyword">else</span> value
|
||||
matchedRule = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">break</span>
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"unrecognized option: <span class="hljs-subst">#{arg}</span>"</span> <span class="hljs-keyword">if</span> isOption <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> matchedRule
|
||||
<span class="hljs-keyword">if</span> seenNonOptionArg <span class="hljs-keyword">or</span> <span class="hljs-keyword">not</span> isOption
|
||||
options.arguments.push arg
|
||||
options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Return the help text for this <strong>OptionParser</strong>, listing and describing all
|
||||
of the valid options, for <code>--help</code> and such.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> help: <span class="hljs-function">-></span>
|
||||
lines = []
|
||||
lines.unshift <span class="hljs-string">"<span class="hljs-subst">#{@banner}</span>\n"</span> <span class="hljs-keyword">if</span> @banner
|
||||
<span class="hljs-keyword">for</span> rule <span class="hljs-keyword">in</span> @rules
|
||||
spaces = <span class="hljs-number">15</span> - rule.longFlag.length
|
||||
spaces = <span class="hljs-keyword">if</span> spaces > <span class="hljs-number">0</span> <span class="hljs-keyword">then</span> repeat <span class="hljs-string">' '</span>, spaces <span class="hljs-keyword">else</span> <span class="hljs-string">''</span>
|
||||
letPart = <span class="hljs-keyword">if</span> rule.shortFlag <span class="hljs-keyword">then</span> rule.shortFlag + <span class="hljs-string">', '</span> <span class="hljs-keyword">else</span> <span class="hljs-string">' '</span>
|
||||
lines.push <span class="hljs-string">' '</span> + letPart + rule.longFlag + spaces + rule.description
|
||||
<span class="hljs-string">"\n<span class="hljs-subst">#{ lines.join(<span class="hljs-string">'\n'</span>) }</span>\n"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<h2 id="helpers">Helpers</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Regex matchers for option flags.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>LONG_FLAG = <span class="hljs-regexp">/^(--\w[\w\-]*)/</span>
|
||||
SHORT_FLAG = <span class="hljs-regexp">/^(-\w)$/</span>
|
||||
MULTI_FLAG = <span class="hljs-regexp">/^-(\w{2,})/</span>
|
||||
OPTIONAL = <span class="hljs-regexp">/\[(\w+(\*?))\]/</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Build and return the list of option rules. If the optional <em>short-flag</em> is
|
||||
unspecified, leave it out by padding with <code>null</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">buildRules</span> = <span class="hljs-params">(rules)</span> -></span>
|
||||
<span class="hljs-keyword">for</span> tuple <span class="hljs-keyword">in</span> rules
|
||||
tuple.unshift <span class="hljs-literal">null</span> <span class="hljs-keyword">if</span> tuple.length < <span class="hljs-number">3</span>
|
||||
buildRule tuple...</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Build a rule from a <code>-o</code> short flag, a <code>--output [DIR]</code> long flag, and the
|
||||
description of what the option does.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">buildRule</span> = <span class="hljs-params">(shortFlag, longFlag, description, options = {})</span> -></span>
|
||||
match = longFlag.match(OPTIONAL)
|
||||
longFlag = longFlag.match(LONG_FLAG)[<span class="hljs-number">1</span>]
|
||||
{
|
||||
name: longFlag.substr <span class="hljs-number">2</span>
|
||||
shortFlag: shortFlag
|
||||
longFlag: longFlag
|
||||
description: description
|
||||
hasArgument: !!(match <span class="hljs-keyword">and</span> match[<span class="hljs-number">1</span>])
|
||||
isList: !!(match <span class="hljs-keyword">and</span> match[<span class="hljs-number">2</span>])
|
||||
}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Normalize arguments by expanding merged flags into multiple flags. This allows
|
||||
you to have <code>-wl</code> be the same as <code>--watch --lint</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">normalizeArguments</span> = <span class="hljs-params">(args)</span> -></span>
|
||||
args = args[..]
|
||||
result = []
|
||||
<span class="hljs-keyword">for</span> arg <span class="hljs-keyword">in</span> args
|
||||
<span class="hljs-keyword">if</span> match = arg.match MULTI_FLAG
|
||||
result.push <span class="hljs-string">'-'</span> + l <span class="hljs-keyword">for</span> l <span class="hljs-keyword">in</span> match[<span class="hljs-number">1</span>].split <span class="hljs-string">''</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
result.push arg
|
||||
result</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
BIN
docs/v1/annotated-source/public/fonts/aller-bold.eot
Normal file
BIN
docs/v1/annotated-source/public/fonts/aller-bold.ttf
Normal file
BIN
docs/v1/annotated-source/public/fonts/aller-bold.woff
Normal file
BIN
docs/v1/annotated-source/public/fonts/aller-light.eot
Normal file
BIN
docs/v1/annotated-source/public/fonts/aller-light.ttf
Normal file
BIN
docs/v1/annotated-source/public/fonts/aller-light.woff
Normal file
BIN
docs/v1/annotated-source/public/fonts/roboto-black.eot
Executable file
BIN
docs/v1/annotated-source/public/fonts/roboto-black.ttf
Executable file
BIN
docs/v1/annotated-source/public/fonts/roboto-black.woff
Executable file
375
docs/v1/annotated-source/public/stylesheets/normalize.css
vendored
Normal file
@@ -0,0 +1,375 @@
|
||||
/*! normalize.css v2.0.1 | MIT License | git.io/normalize */
|
||||
|
||||
/* ==========================================================================
|
||||
HTML5 display definitions
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Corrects `block` display not defined in IE 8/9.
|
||||
*/
|
||||
|
||||
article,
|
||||
aside,
|
||||
details,
|
||||
figcaption,
|
||||
figure,
|
||||
footer,
|
||||
header,
|
||||
hgroup,
|
||||
nav,
|
||||
section,
|
||||
summary {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/*
|
||||
* Corrects `inline-block` display not defined in IE 8/9.
|
||||
*/
|
||||
|
||||
audio,
|
||||
canvas,
|
||||
video {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
/*
|
||||
* Prevents modern browsers from displaying `audio` without controls.
|
||||
* Remove excess height in iOS 5 devices.
|
||||
*/
|
||||
|
||||
audio:not([controls]) {
|
||||
display: none;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses styling for `hidden` attribute not present in IE 8/9.
|
||||
*/
|
||||
|
||||
[hidden] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Base
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* 1. Sets default font family to sans-serif.
|
||||
* 2. Prevents iOS text size adjust after orientation change, without disabling
|
||||
* user zoom.
|
||||
*/
|
||||
|
||||
html {
|
||||
font-family: sans-serif; /* 1 */
|
||||
-webkit-text-size-adjust: 100%; /* 2 */
|
||||
-ms-text-size-adjust: 100%; /* 2 */
|
||||
}
|
||||
|
||||
/*
|
||||
* Removes default margin.
|
||||
*/
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Links
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Addresses `outline` inconsistency between Chrome and other browsers.
|
||||
*/
|
||||
|
||||
a:focus {
|
||||
outline: thin dotted;
|
||||
}
|
||||
|
||||
/*
|
||||
* Improves readability when focused and also mouse hovered in all browsers.
|
||||
*/
|
||||
|
||||
a:active,
|
||||
a:hover {
|
||||
outline: 0;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Typography
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Addresses `h1` font sizes within `section` and `article` in Firefox 4+,
|
||||
* Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
h1 {
|
||||
font-size: 2em;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses styling not present in IE 8/9, Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
abbr[title] {
|
||||
border-bottom: 1px dotted;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses style set to `bolder` in Firefox 4+, Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
b,
|
||||
strong {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses styling not present in Safari 5 and Chrome.
|
||||
*/
|
||||
|
||||
dfn {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses styling not present in IE 8/9.
|
||||
*/
|
||||
|
||||
mark {
|
||||
background: #ff0;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Corrects font family set oddly in Safari 5 and Chrome.
|
||||
*/
|
||||
|
||||
code,
|
||||
kbd,
|
||||
pre,
|
||||
samp {
|
||||
font-family: monospace, serif;
|
||||
font-size: 1em;
|
||||
}
|
||||
|
||||
/*
|
||||
* Improves readability of pre-formatted text in all browsers.
|
||||
*/
|
||||
|
||||
pre {
|
||||
white-space: pre;
|
||||
white-space: pre-wrap;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
/*
|
||||
* Sets consistent quote types.
|
||||
*/
|
||||
|
||||
q {
|
||||
quotes: "\201C" "\201D" "\2018" "\2019";
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses inconsistent and variable font size in all browsers.
|
||||
*/
|
||||
|
||||
small {
|
||||
font-size: 80%;
|
||||
}
|
||||
|
||||
/*
|
||||
* Prevents `sub` and `sup` affecting `line-height` in all browsers.
|
||||
*/
|
||||
|
||||
sub,
|
||||
sup {
|
||||
font-size: 75%;
|
||||
line-height: 0;
|
||||
position: relative;
|
||||
vertical-align: baseline;
|
||||
}
|
||||
|
||||
sup {
|
||||
top: -0.5em;
|
||||
}
|
||||
|
||||
sub {
|
||||
bottom: -0.25em;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Embedded content
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Removes border when inside `a` element in IE 8/9.
|
||||
*/
|
||||
|
||||
img {
|
||||
border: 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Corrects overflow displayed oddly in IE 9.
|
||||
*/
|
||||
|
||||
svg:not(:root) {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Figures
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Addresses margin not present in IE 8/9 and Safari 5.
|
||||
*/
|
||||
|
||||
figure {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Forms
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Define consistent border, margin, and padding.
|
||||
*/
|
||||
|
||||
fieldset {
|
||||
border: 1px solid #c0c0c0;
|
||||
margin: 0 2px;
|
||||
padding: 0.35em 0.625em 0.75em;
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Corrects color not being inherited in IE 8/9.
|
||||
* 2. Remove padding so people aren't caught out if they zero out fieldsets.
|
||||
*/
|
||||
|
||||
legend {
|
||||
border: 0; /* 1 */
|
||||
padding: 0; /* 2 */
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Corrects font family not being inherited in all browsers.
|
||||
* 2. Corrects font size not being inherited in all browsers.
|
||||
* 3. Addresses margins set differently in Firefox 4+, Safari 5, and Chrome
|
||||
*/
|
||||
|
||||
button,
|
||||
input,
|
||||
select,
|
||||
textarea {
|
||||
font-family: inherit; /* 1 */
|
||||
font-size: 100%; /* 2 */
|
||||
margin: 0; /* 3 */
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses Firefox 4+ setting `line-height` on `input` using `!important` in
|
||||
* the UA stylesheet.
|
||||
*/
|
||||
|
||||
button,
|
||||
input {
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
|
||||
* and `video` controls.
|
||||
* 2. Corrects inability to style clickable `input` types in iOS.
|
||||
* 3. Improves usability and consistency of cursor style between image-type
|
||||
* `input` and others.
|
||||
*/
|
||||
|
||||
button,
|
||||
html input[type="button"], /* 1 */
|
||||
input[type="reset"],
|
||||
input[type="submit"] {
|
||||
-webkit-appearance: button; /* 2 */
|
||||
cursor: pointer; /* 3 */
|
||||
}
|
||||
|
||||
/*
|
||||
* Re-set default cursor for disabled elements.
|
||||
*/
|
||||
|
||||
button[disabled],
|
||||
input[disabled] {
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Addresses box sizing set to `content-box` in IE 8/9.
|
||||
* 2. Removes excess padding in IE 8/9.
|
||||
*/
|
||||
|
||||
input[type="checkbox"],
|
||||
input[type="radio"] {
|
||||
box-sizing: border-box; /* 1 */
|
||||
padding: 0; /* 2 */
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Addresses `appearance` set to `searchfield` in Safari 5 and Chrome.
|
||||
* 2. Addresses `box-sizing` set to `border-box` in Safari 5 and Chrome
|
||||
* (include `-moz` to future-proof).
|
||||
*/
|
||||
|
||||
input[type="search"] {
|
||||
-webkit-appearance: textfield; /* 1 */
|
||||
-moz-box-sizing: content-box;
|
||||
-webkit-box-sizing: content-box; /* 2 */
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
/*
|
||||
* Removes inner padding and search cancel button in Safari 5 and Chrome
|
||||
* on OS X.
|
||||
*/
|
||||
|
||||
input[type="search"]::-webkit-search-cancel-button,
|
||||
input[type="search"]::-webkit-search-decoration {
|
||||
-webkit-appearance: none;
|
||||
}
|
||||
|
||||
/*
|
||||
* Removes inner padding and border in Firefox 4+.
|
||||
*/
|
||||
|
||||
button::-moz-focus-inner,
|
||||
input::-moz-focus-inner {
|
||||
border: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Removes default vertical scrollbar in IE 8/9.
|
||||
* 2. Improves readability and alignment in all browsers.
|
||||
*/
|
||||
|
||||
textarea {
|
||||
overflow: auto; /* 1 */
|
||||
vertical-align: top; /* 2 */
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Tables
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Remove most spacing between table cells.
|
||||
*/
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
}
|
||||
251
docs/v1/annotated-source/register.html
Normal file
@@ -0,0 +1,251 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>register.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>register.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffee-script'</span>
|
||||
child_process = <span class="hljs-built_in">require</span> <span class="hljs-string">'child_process'</span>
|
||||
helpers = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Load and run a CoffeeScript file for Node, stripping any <code>BOM</code>s.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">loadFile</span> = <span class="hljs-params">(<span class="hljs-built_in">module</span>, filename)</span> -></span>
|
||||
answer = CoffeeScript._compileFile filename, <span class="hljs-literal">no</span>, <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-built_in">module</span>._compile answer, filename</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>If the installed version of Node supports <code>require.extensions</code>, register
|
||||
CoffeeScript as an extension.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> <span class="hljs-built_in">require</span>.extensions
|
||||
<span class="hljs-keyword">for</span> ext <span class="hljs-keyword">in</span> CoffeeScript.FILE_EXTENSIONS
|
||||
<span class="hljs-built_in">require</span>.extensions[ext] = loadFile</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Patch Node’s module loader to be able to handle multi-dot extensions.
|
||||
This is a horrible thing that should not be required.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> Module = <span class="hljs-built_in">require</span> <span class="hljs-string">'module'</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">findExtension</span> = <span class="hljs-params">(filename)</span> -></span>
|
||||
extensions = path.basename(filename).split <span class="hljs-string">'.'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Remove the initial dot from dotfiles.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> extensions.shift() <span class="hljs-keyword">if</span> extensions[<span class="hljs-number">0</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">''</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Start with the longest possible extension and work our way shortwards.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">while</span> extensions.shift()
|
||||
curExtension = <span class="hljs-string">'.'</span> + extensions.join <span class="hljs-string">'.'</span>
|
||||
<span class="hljs-keyword">return</span> curExtension <span class="hljs-keyword">if</span> Module._extensions[curExtension]
|
||||
<span class="hljs-string">'.js'</span>
|
||||
|
||||
Module::load = <span class="hljs-function"><span class="hljs-params">(filename)</span> -></span>
|
||||
@filename = filename
|
||||
@paths = Module._nodeModulePaths path.dirname filename
|
||||
extension = findExtension filename
|
||||
Module._extensions[extension](<span class="hljs-keyword">this</span>, filename)
|
||||
@loaded = <span class="hljs-literal">true</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>If we’re on Node, patch <code>child_process.fork</code> so that Coffee scripts are able
|
||||
to fork both CoffeeScript files, and JavaScript files, directly.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> child_process
|
||||
{fork} = child_process
|
||||
binary = <span class="hljs-built_in">require</span>.resolve <span class="hljs-string">'../../bin/coffee'</span>
|
||||
child_process.fork = <span class="hljs-function"><span class="hljs-params">(path, args, options)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> helpers.isCoffee path
|
||||
<span class="hljs-keyword">unless</span> Array.isArray args
|
||||
options = args <span class="hljs-keyword">or</span> {}
|
||||
args = []
|
||||
args = [path].concat args
|
||||
path = binary
|
||||
fork path, args, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
624
docs/v1/annotated-source/repl.html
Normal file
@@ -0,0 +1,624 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>repl.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>repl.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>fs = <span class="hljs-built_in">require</span> <span class="hljs-string">'fs'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span>
|
||||
vm = <span class="hljs-built_in">require</span> <span class="hljs-string">'vm'</span>
|
||||
nodeREPL = <span class="hljs-built_in">require</span> <span class="hljs-string">'repl'</span>
|
||||
CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffee-script'</span>
|
||||
{merge, updateSyntaxError} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
|
||||
replDefaults =
|
||||
prompt: <span class="hljs-string">'coffee> '</span>,
|
||||
historyFile: path.join process.env.HOME, <span class="hljs-string">'.coffee_history'</span> <span class="hljs-keyword">if</span> process.env.HOME
|
||||
historyMaxInputSize: <span class="hljs-number">10240</span>
|
||||
eval: <span class="hljs-function"><span class="hljs-params">(input, context, filename, cb)</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>XXX: multiline hack.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> input = input.replace <span class="hljs-regexp">/\uFF00/g</span>, <span class="hljs-string">'\n'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Node’s REPL sends the input ending with a newline and then wrapped in
|
||||
parens. Unwrap all that.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> input = input.replace <span class="hljs-regexp">/^\(([\s\S]*)\n\)$/m</span>, <span class="hljs-string">'$1'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Node’s REPL v6.9.1+ sends the input wrapped in a try/catch statement.
|
||||
Unwrap that too.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> input = input.replace <span class="hljs-regexp">/^\s*try\s*{([\s\S]*)}\s*catch.*$/m</span>, <span class="hljs-string">'$1'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Require AST nodes to do some AST manipulation.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> {Block, Assign, Value, Literal} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./nodes'</span>
|
||||
|
||||
<span class="hljs-keyword">try</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Tokenize the clean input.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> tokens = CoffeeScript.tokens input</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Collect referenced variable names just like in <code>CoffeeScript.compile</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> referencedVars = (
|
||||
token[<span class="hljs-number">1</span>] <span class="hljs-keyword">for</span> token <span class="hljs-keyword">in</span> tokens <span class="hljs-keyword">when</span> token[<span class="hljs-number">0</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">'IDENTIFIER'</span>
|
||||
)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Generate the AST of the tokens.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> ast = CoffeeScript.nodes tokens</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Add assignment to <code>_</code> variable to force the input to be an expression.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> ast = <span class="hljs-keyword">new</span> Block [
|
||||
<span class="hljs-keyword">new</span> Assign (<span class="hljs-keyword">new</span> Value <span class="hljs-keyword">new</span> Literal <span class="hljs-string">'_'</span>), ast, <span class="hljs-string">'='</span>
|
||||
]
|
||||
js = ast.compile {bare: <span class="hljs-literal">yes</span>, locals: Object.keys(context), referencedVars}
|
||||
cb <span class="hljs-literal">null</span>, runInContext js, context, filename
|
||||
<span class="hljs-keyword">catch</span> err</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>AST’s <code>compile</code> does not add source code information to syntax errors.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> updateSyntaxError err, input
|
||||
cb err
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">runInContext</span> = <span class="hljs-params">(js, context, filename)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> context <span class="hljs-keyword">is</span> <span class="hljs-built_in">global</span>
|
||||
vm.runInThisContext js, filename
|
||||
<span class="hljs-keyword">else</span>
|
||||
vm.runInContext js, context, filename
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">addMultilineHandler</span> = <span class="hljs-params">(repl)</span> -></span>
|
||||
{rli, inputStream, outputStream} = repl</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Node 0.11.12 changed API, prompt is now _prompt.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> origPrompt = repl._prompt ? repl.prompt
|
||||
|
||||
multiline =
|
||||
enabled: <span class="hljs-literal">off</span>
|
||||
initialPrompt: origPrompt.replace <span class="hljs-regexp">/^[^> ]*/</span>, <span class="hljs-function"><span class="hljs-params">(x)</span> -></span> x.replace <span class="hljs-regexp">/./g</span>, <span class="hljs-string">'-'</span>
|
||||
prompt: origPrompt.replace <span class="hljs-regexp">/^[^> ]*>?/</span>, <span class="hljs-function"><span class="hljs-params">(x)</span> -></span> x.replace <span class="hljs-regexp">/./g</span>, <span class="hljs-string">'.'</span>
|
||||
buffer: <span class="hljs-string">''</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Proxy node’s line listener</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> nodeLineListener = rli.listeners(<span class="hljs-string">'line'</span>)[<span class="hljs-number">0</span>]
|
||||
rli.removeListener <span class="hljs-string">'line'</span>, nodeLineListener
|
||||
rli.<span class="hljs-literal">on</span> <span class="hljs-string">'line'</span>, <span class="hljs-function"><span class="hljs-params">(cmd)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> multiline.enabled
|
||||
multiline.buffer += <span class="hljs-string">"<span class="hljs-subst">#{cmd}</span>\n"</span>
|
||||
rli.setPrompt multiline.prompt
|
||||
rli.prompt <span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
rli.setPrompt origPrompt
|
||||
nodeLineListener cmd
|
||||
<span class="hljs-keyword">return</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Handle Ctrl-v</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> inputStream.<span class="hljs-literal">on</span> <span class="hljs-string">'keypress'</span>, <span class="hljs-function"><span class="hljs-params">(char, key)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> key <span class="hljs-keyword">and</span> key.ctrl <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> key.meta <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> key.shift <span class="hljs-keyword">and</span> key.name <span class="hljs-keyword">is</span> <span class="hljs-string">'v'</span>
|
||||
<span class="hljs-keyword">if</span> multiline.enabled</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>allow arbitrarily switching between modes any time before multiple lines are entered</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">unless</span> multiline.buffer.match <span class="hljs-regexp">/\n/</span>
|
||||
multiline.enabled = <span class="hljs-keyword">not</span> multiline.enabled
|
||||
rli.setPrompt origPrompt
|
||||
rli.prompt <span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">return</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>no-op unless the current line is empty</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> rli.line? <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> rli.line.match <span class="hljs-regexp">/^\s*$/</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>eval, print, loop</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> multiline.enabled = <span class="hljs-keyword">not</span> multiline.enabled
|
||||
rli.line = <span class="hljs-string">''</span>
|
||||
rli.cursor = <span class="hljs-number">0</span>
|
||||
rli.output.cursorTo <span class="hljs-number">0</span>
|
||||
rli.output.clearLine <span class="hljs-number">1</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>XXX: multiline hack</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> multiline.buffer = multiline.buffer.replace <span class="hljs-regexp">/\n/g</span>, <span class="hljs-string">'\uFF00'</span>
|
||||
rli.emit <span class="hljs-string">'line'</span>, multiline.buffer
|
||||
multiline.buffer = <span class="hljs-string">''</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
multiline.enabled = <span class="hljs-keyword">not</span> multiline.enabled
|
||||
rli.setPrompt multiline.initialPrompt
|
||||
rli.prompt <span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">return</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>Store and load command history from a file</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">addHistory</span> = <span class="hljs-params">(repl, filename, maxSize)</span> -></span>
|
||||
lastLine = <span class="hljs-literal">null</span>
|
||||
<span class="hljs-keyword">try</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Get file info and at most maxSize of command history</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> stat = fs.statSync filename
|
||||
size = Math.min maxSize, stat.size</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<p>Read last <code>size</code> bytes from the file</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> readFd = fs.openSync filename, <span class="hljs-string">'r'</span>
|
||||
buffer = <span class="hljs-keyword">new</span> Buffer(size)
|
||||
fs.readSync readFd, buffer, <span class="hljs-number">0</span>, size, stat.size - size
|
||||
fs.closeSync readFd</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
<p>Set the history on the interpreter</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.rli.history = buffer.toString().split(<span class="hljs-string">'\n'</span>).reverse()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>If the history file was truncated we should pop off a potential partial line</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.rli.history.pop() <span class="hljs-keyword">if</span> stat.size > maxSize</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-23">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-23">¶</a>
|
||||
</div>
|
||||
<p>Shift off the final blank newline</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.rli.history.shift() <span class="hljs-keyword">if</span> repl.rli.history[<span class="hljs-number">0</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">''</span>
|
||||
repl.rli.historyIndex = <span class="hljs-number">-1</span>
|
||||
lastLine = repl.rli.history[<span class="hljs-number">0</span>]
|
||||
|
||||
fd = fs.openSync filename, <span class="hljs-string">'a'</span>
|
||||
|
||||
repl.rli.addListener <span class="hljs-string">'line'</span>, <span class="hljs-function"><span class="hljs-params">(code)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> code <span class="hljs-keyword">and</span> code.length <span class="hljs-keyword">and</span> code <span class="hljs-keyword">isnt</span> <span class="hljs-string">'.history'</span> <span class="hljs-keyword">and</span> code <span class="hljs-keyword">isnt</span> <span class="hljs-string">'.exit'</span> <span class="hljs-keyword">and</span> lastLine <span class="hljs-keyword">isnt</span> code</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-24">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-24">¶</a>
|
||||
</div>
|
||||
<p>Save the latest command in the file</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> fs.writeSync fd, <span class="hljs-string">"<span class="hljs-subst">#{code}</span>\n"</span>
|
||||
lastLine = code
|
||||
|
||||
repl.<span class="hljs-literal">on</span> <span class="hljs-string">'exit'</span>, <span class="hljs-function">-></span> fs.closeSync fd</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-25">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-25">¶</a>
|
||||
</div>
|
||||
<p>Add a command to show the history stack</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.commands[getCommandId(repl, <span class="hljs-string">'history'</span>)] =
|
||||
help: <span class="hljs-string">'Show command history'</span>
|
||||
action: <span class="hljs-function">-></span>
|
||||
repl.outputStream.write <span class="hljs-string">"<span class="hljs-subst">#{repl.rli.history[..].reverse().join <span class="hljs-string">'\n'</span>}</span>\n"</span>
|
||||
repl.displayPrompt()
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">getCommandId</span> = <span class="hljs-params">(repl, commandName)</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-26">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-26">¶</a>
|
||||
</div>
|
||||
<p>Node 0.11 changed API, a command such as ‘.help’ is now stored as ‘help’</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> commandsHaveLeadingDot = repl.commands[<span class="hljs-string">'.help'</span>]?
|
||||
<span class="hljs-keyword">if</span> commandsHaveLeadingDot <span class="hljs-keyword">then</span> <span class="hljs-string">".<span class="hljs-subst">#{commandName}</span>"</span> <span class="hljs-keyword">else</span> commandName
|
||||
|
||||
<span class="hljs-built_in">module</span>.exports =
|
||||
start: <span class="hljs-function"><span class="hljs-params">(opts = {})</span> -></span>
|
||||
[major, minor, build] = process.versions.node.split(<span class="hljs-string">'.'</span>).map (n) -> parseInt(n)
|
||||
|
||||
<span class="hljs-keyword">if</span> major <span class="hljs-keyword">is</span> <span class="hljs-number">0</span> <span class="hljs-keyword">and</span> minor < <span class="hljs-number">8</span>
|
||||
<span class="hljs-built_in">console</span>.warn <span class="hljs-string">"Node 0.8.0+ required for CoffeeScript REPL"</span>
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
|
||||
CoffeeScript.register()
|
||||
process.argv = [<span class="hljs-string">'coffee'</span>].concat process.argv[<span class="hljs-number">2.</span>.]
|
||||
opts = merge replDefaults, opts
|
||||
repl = nodeREPL.start opts
|
||||
runInContext opts.prelude, repl.context, <span class="hljs-string">'prelude'</span> <span class="hljs-keyword">if</span> opts.prelude
|
||||
repl.<span class="hljs-literal">on</span> <span class="hljs-string">'exit'</span>, <span class="hljs-function">-></span> repl.outputStream.write <span class="hljs-string">'\n'</span> <span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> repl.rli.closed
|
||||
addMultilineHandler repl
|
||||
addHistory repl, opts.historyFile, opts.historyMaxInputSize <span class="hljs-keyword">if</span> opts.historyFile</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-27">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-27">¶</a>
|
||||
</div>
|
||||
<p>Adapt help inherited from the node REPL</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.commands[getCommandId(repl, <span class="hljs-string">'load'</span>)].help = <span class="hljs-string">'Load code from a file into this REPL session'</span>
|
||||
repl</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
1241
docs/v1/annotated-source/rewriter.html
Normal file
398
docs/v1/annotated-source/scope.html
Normal file
@@ -0,0 +1,398 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>scope.litcoffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>scope.litcoffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>The <strong>Scope</strong> class regulates lexical scoping within CoffeeScript. As you
|
||||
generate code, you create a tree of scopes in the same shape as the nested
|
||||
function bodies. Each scope knows about the variables declared within it,
|
||||
and has a reference to its parent enclosing scope. In this way, we know which
|
||||
variables are new and need to be declared with <code>var</code>, and which are shared
|
||||
with external scopes.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.Scope = <span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Scope</span></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Initialize a scope with its parent, for lookups up the chain,
|
||||
as well as a reference to the <strong>Block</strong> node it belongs to, which is
|
||||
where it should declare its variables, a reference to the function that
|
||||
it belongs to, and a list of variables referenced in the source code
|
||||
and therefore should be avoided when generating variables.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> constructor: <span class="hljs-function"><span class="hljs-params">(@parent, @expressions, @method, @referencedVars)</span> -></span>
|
||||
@variables = [{name: <span class="hljs-string">'arguments'</span>, type: <span class="hljs-string">'arguments'</span>}]
|
||||
@positions = {}
|
||||
@utilities = {} <span class="hljs-keyword">unless</span> @parent</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>The <code>@root</code> is the top-level <strong>Scope</strong> object for a given file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> @root = @parent?.root ? <span class="hljs-keyword">this</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Adds a new variable or overrides an existing one.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> add: <span class="hljs-function"><span class="hljs-params">(name, type, immediate)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> @parent.add name, type, immediate <span class="hljs-keyword">if</span> @shared <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> immediate
|
||||
<span class="hljs-keyword">if</span> Object::hasOwnProperty.call @positions, name
|
||||
@variables[@positions[name]].type = type
|
||||
<span class="hljs-keyword">else</span>
|
||||
@positions[name] = @variables.push({name, type}) - <span class="hljs-number">1</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>When <code>super</code> is called, we need to find the name of the current method we’re
|
||||
in, so that we know how to invoke the same method of the parent class. This
|
||||
can get complicated if super is being called from an inner function.
|
||||
<code>namedMethod</code> will walk up the scope tree until it either finds the first
|
||||
function object that has a name filled in, or bottoms out.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> namedMethod: <span class="hljs-function">-></span>
|
||||
<span class="hljs-keyword">return</span> @method <span class="hljs-keyword">if</span> @method?.name <span class="hljs-keyword">or</span> !@parent
|
||||
@parent.namedMethod()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Look up a variable name in lexical scope, and declare it if it does not
|
||||
already exist.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> find: <span class="hljs-function"><span class="hljs-params">(name, type = <span class="hljs-string">'var'</span>)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-literal">yes</span> <span class="hljs-keyword">if</span> @check name
|
||||
@add name, type
|
||||
<span class="hljs-literal">no</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Reserve a variable name as originating from a function parameter for this
|
||||
scope. No <code>var</code> required for internal references.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> parameter: <span class="hljs-function"><span class="hljs-params">(name)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> @shared <span class="hljs-keyword">and</span> @parent.check name, <span class="hljs-literal">yes</span>
|
||||
@add name, <span class="hljs-string">'param'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Just check to see if a variable has already been declared, without reserving,
|
||||
walks up to the root scope.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> check: <span class="hljs-function"><span class="hljs-params">(name)</span> -></span>
|
||||
!!(@type(name) <span class="hljs-keyword">or</span> @parent?.check(name))</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Generate a temporary variable name at the given index.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> temporary: <span class="hljs-function"><span class="hljs-params">(name, index, single=<span class="hljs-literal">false</span>)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> single
|
||||
startCode = name.charCodeAt(<span class="hljs-number">0</span>)
|
||||
endCode = <span class="hljs-string">'z'</span>.charCodeAt(<span class="hljs-number">0</span>)
|
||||
diff = endCode - startCode
|
||||
newCode = startCode + index % (diff + <span class="hljs-number">1</span>)
|
||||
letter = String.fromCharCode(newCode)
|
||||
num = index <span class="hljs-regexp">//</span> (diff + <span class="hljs-number">1</span>)
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{letter}</span><span class="hljs-subst">#{num <span class="hljs-keyword">or</span> <span class="hljs-string">''</span>}</span>"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{name}</span><span class="hljs-subst">#{index <span class="hljs-keyword">or</span> <span class="hljs-string">''</span>}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Gets the type of a variable.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> type: <span class="hljs-function"><span class="hljs-params">(name)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> v.type <span class="hljs-keyword">for</span> v <span class="hljs-keyword">in</span> @variables <span class="hljs-keyword">when</span> v.name <span class="hljs-keyword">is</span> name
|
||||
<span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>If we need to store an intermediate result, find an available name for a
|
||||
compiler-generated variable. <code>_var</code>, <code>_var2</code>, and so on…</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> freeVariable: <span class="hljs-function"><span class="hljs-params">(name, options={})</span> -></span>
|
||||
index = <span class="hljs-number">0</span>
|
||||
<span class="hljs-keyword">loop</span>
|
||||
temp = @temporary name, index, options.single
|
||||
<span class="hljs-keyword">break</span> <span class="hljs-keyword">unless</span> @check(temp) <span class="hljs-keyword">or</span> temp <span class="hljs-keyword">in</span> @root.referencedVars
|
||||
index++
|
||||
@add temp, <span class="hljs-string">'var'</span>, <span class="hljs-literal">yes</span> <span class="hljs-keyword">if</span> options.reserve ? <span class="hljs-literal">true</span>
|
||||
temp</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Ensure that an assignment is made at the top of this scope
|
||||
(or at the top-level scope, if requested).</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> assign: <span class="hljs-function"><span class="hljs-params">(name, value)</span> -></span>
|
||||
@add name, {value, assigned: <span class="hljs-literal">yes</span>}, <span class="hljs-literal">yes</span>
|
||||
@hasAssignments = <span class="hljs-literal">yes</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Does this scope have any declared variables?</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> hasDeclarations: <span class="hljs-function">-></span>
|
||||
!!@declaredVariables().length</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Return the list of variables first declared in this scope.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> declaredVariables: <span class="hljs-function">-></span>
|
||||
(v.name <span class="hljs-keyword">for</span> v <span class="hljs-keyword">in</span> @variables <span class="hljs-keyword">when</span> v.type <span class="hljs-keyword">is</span> <span class="hljs-string">'var'</span>).sort()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>Return the list of assignments that are supposed to be made at the top
|
||||
of this scope.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> assignedVariables: <span class="hljs-function">-></span>
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{v.name}</span> = <span class="hljs-subst">#{v.type.value}</span>"</span> <span class="hljs-keyword">for</span> v <span class="hljs-keyword">in</span> @variables <span class="hljs-keyword">when</span> v.type.assigned</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
523
docs/v1/annotated-source/sourcemap.html
Normal file
@@ -0,0 +1,523 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>sourcemap.litcoffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffee-script.html">
|
||||
coffee-script.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>sourcemap.litcoffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>Source maps allow JavaScript runtimes to match running JavaScript back to
|
||||
the original source code that corresponds to it. This can be minified
|
||||
JavaScript, but in our case, we’re concerned with mapping pretty-printed
|
||||
JavaScript back to CoffeeScript.</p>
|
||||
<p>In order to produce maps, we must keep track of positions (line number, column number)
|
||||
that originated every node in the syntax tree, and be able to generate a
|
||||
<a href="https://docs.google.com/document/d/1U1RGAehQwRypUTovF1KRlpiOFze0b-_2gc6fAH0KY0k/edit">map file</a>
|
||||
— which is a compact, VLQ-encoded representation of the JSON serialization
|
||||
of this information — to write out alongside the generated JavaScript.</p>
|
||||
<h2 id="linemap">LineMap</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>A <strong>LineMap</strong> object keeps track of information about original line and column
|
||||
positions for a single line of output JavaScript code.
|
||||
<strong>SourceMaps</strong> are implemented in terms of <strong>LineMaps</strong>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">LineMap</span></span>
|
||||
constructor: <span class="hljs-function"><span class="hljs-params">(@line)</span> -></span>
|
||||
@columns = []
|
||||
|
||||
add: <span class="hljs-function"><span class="hljs-params">(column, [sourceLine, sourceColumn], options={})</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> @columns[column] <span class="hljs-keyword">and</span> options.noReplace
|
||||
@columns[column] = {line: @line, column, sourceLine, sourceColumn}
|
||||
|
||||
sourceLocation: <span class="hljs-function"><span class="hljs-params">(column)</span> -></span>
|
||||
column-- <span class="hljs-keyword">until</span> (mapping = @columns[column]) <span class="hljs-keyword">or</span> (column <= <span class="hljs-number">0</span>)
|
||||
mapping <span class="hljs-keyword">and</span> [mapping.sourceLine, mapping.sourceColumn]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<h2 id="sourcemap">SourceMap</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Maps locations in a single generated JavaScript file back to locations in
|
||||
the original CoffeeScript source file.</p>
|
||||
<p>This is intentionally agnostic towards how a source map might be represented on
|
||||
disk. Once the compiler is ready to produce a “v3”-style source map, we can walk
|
||||
through the arrays of line and column buffer to produce it.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">SourceMap</span></span>
|
||||
constructor: <span class="hljs-function">-></span>
|
||||
@lines = []</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Adds a mapping to this SourceMap. <code>sourceLocation</code> and <code>generatedLocation</code>
|
||||
are both <code>[line, column]</code> arrays. If <code>options.noReplace</code> is true, then if there
|
||||
is already a mapping for the specified <code>line</code> and <code>column</code>, this will have no
|
||||
effect.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> add: <span class="hljs-function"><span class="hljs-params">(sourceLocation, generatedLocation, options = {})</span> -></span>
|
||||
[line, column] = generatedLocation
|
||||
lineMap = (@lines[line] <span class="hljs-keyword">or</span>= <span class="hljs-keyword">new</span> LineMap(line))
|
||||
lineMap.add column, sourceLocation, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Look up the original position of a given <code>line</code> and <code>column</code> in the generated
|
||||
code.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> sourceLocation: <span class="hljs-function"><span class="hljs-params">([line, column])</span> -></span>
|
||||
line-- <span class="hljs-keyword">until</span> (lineMap = @lines[line]) <span class="hljs-keyword">or</span> (line <= <span class="hljs-number">0</span>)
|
||||
lineMap <span class="hljs-keyword">and</span> lineMap.sourceLocation column</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<h2 id="v3-sourcemap-generation">V3 SourceMap Generation</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Builds up a V3 source map, returning the generated JSON as a string.
|
||||
<code>options.sourceRoot</code> may be used to specify the sourceRoot written to the source
|
||||
map. Also, <code>options.sourceFiles</code> and <code>options.generatedFile</code> may be passed to
|
||||
set “sources” and “file”, respectively.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> generate: <span class="hljs-function"><span class="hljs-params">(options = {}, code = <span class="hljs-literal">null</span>)</span> -></span>
|
||||
writingline = <span class="hljs-number">0</span>
|
||||
lastColumn = <span class="hljs-number">0</span>
|
||||
lastSourceLine = <span class="hljs-number">0</span>
|
||||
lastSourceColumn = <span class="hljs-number">0</span>
|
||||
needComma = <span class="hljs-literal">no</span>
|
||||
buffer = <span class="hljs-string">""</span>
|
||||
|
||||
<span class="hljs-keyword">for</span> lineMap, lineNumber <span class="hljs-keyword">in</span> @lines <span class="hljs-keyword">when</span> lineMap
|
||||
<span class="hljs-keyword">for</span> mapping <span class="hljs-keyword">in</span> lineMap.columns <span class="hljs-keyword">when</span> mapping
|
||||
<span class="hljs-keyword">while</span> writingline < mapping.line
|
||||
lastColumn = <span class="hljs-number">0</span>
|
||||
needComma = <span class="hljs-literal">no</span>
|
||||
buffer += <span class="hljs-string">";"</span>
|
||||
writingline++</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Write a comma if we’ve already written a segment on this line.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> needComma
|
||||
buffer += <span class="hljs-string">","</span>
|
||||
needComma = <span class="hljs-literal">no</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Write the next segment. Segments can be 1, 4, or 5 values. If just one, then it
|
||||
is a generated column which doesn’t match anything in the source code.</p>
|
||||
<p>The starting column in the generated source, relative to any previous recorded
|
||||
column for the current line:</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> buffer += @encodeVlq mapping.column - lastColumn
|
||||
lastColumn = mapping.column</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>The index into the list of sources:</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> buffer += @encodeVlq <span class="hljs-number">0</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>The starting line in the original source, relative to the previous source line.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> buffer += @encodeVlq mapping.sourceLine - lastSourceLine
|
||||
lastSourceLine = mapping.sourceLine</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>The starting column in the original source, relative to the previous column.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> buffer += @encodeVlq mapping.sourceColumn - lastSourceColumn
|
||||
lastSourceColumn = mapping.sourceColumn
|
||||
needComma = <span class="hljs-literal">yes</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Produce the canonical JSON object format for a “v3” source map.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> v3 =
|
||||
version: <span class="hljs-number">3</span>
|
||||
file: options.generatedFile <span class="hljs-keyword">or</span> <span class="hljs-string">''</span>
|
||||
sourceRoot: options.sourceRoot <span class="hljs-keyword">or</span> <span class="hljs-string">''</span>
|
||||
sources: options.sourceFiles <span class="hljs-keyword">or</span> [<span class="hljs-string">''</span>]
|
||||
names: []
|
||||
mappings: buffer
|
||||
|
||||
v3.sourcesContent = [code] <span class="hljs-keyword">if</span> options.inlineMap
|
||||
|
||||
v3</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<h2 id="base64-vlq-encoding">Base64 VLQ Encoding</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>Note that SourceMap VLQ encoding is “backwards”. MIDI-style VLQ encoding puts
|
||||
the most-significant-bit (MSB) from the original value into the MSB of the VLQ
|
||||
encoded value (see <a href="http://en.wikipedia.org/wiki/File:Uintvar_coding.svg">Wikipedia</a>).
|
||||
SourceMap VLQ does things the other way around, with the least significat four
|
||||
bits of the original value encoded into the first byte of the VLQ encoded value.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> VLQ_SHIFT = <span class="hljs-number">5</span>
|
||||
VLQ_CONTINUATION_BIT = <span class="hljs-number">1</span> << VLQ_SHIFT <span class="hljs-comment"># 0010 0000</span>
|
||||
VLQ_VALUE_MASK = VLQ_CONTINUATION_BIT - <span class="hljs-number">1</span> <span class="hljs-comment"># 0001 1111</span>
|
||||
|
||||
encodeVlq: <span class="hljs-function"><span class="hljs-params">(value)</span> -></span>
|
||||
answer = <span class="hljs-string">''</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>Least significant bit represents the sign.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> signBit = <span class="hljs-keyword">if</span> value < <span class="hljs-number">0</span> <span class="hljs-keyword">then</span> <span class="hljs-number">1</span> <span class="hljs-keyword">else</span> <span class="hljs-number">0</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>The next bits are the actual value.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> valueToEncode = (Math.abs(value) << <span class="hljs-number">1</span>) + signBit</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Make sure we encode at least one character, even if valueToEncode is 0.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">while</span> valueToEncode <span class="hljs-keyword">or</span> <span class="hljs-keyword">not</span> answer
|
||||
nextChunk = valueToEncode & VLQ_VALUE_MASK
|
||||
valueToEncode = valueToEncode >> VLQ_SHIFT
|
||||
nextChunk |= VLQ_CONTINUATION_BIT <span class="hljs-keyword">if</span> valueToEncode
|
||||
answer += @encodeBase64 nextChunk
|
||||
|
||||
answer</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<h2 id="regular-base64-encoding">Regular Base64 Encoding</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> BASE64_CHARS = <span class="hljs-string">'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'</span>
|
||||
|
||||
encodeBase64: <span class="hljs-function"><span class="hljs-params">(value)</span> -></span>
|
||||
BASE64_CHARS[value] <span class="hljs-keyword">or</span> <span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"Cannot Base64 encode value: <span class="hljs-subst">#{value}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>Our API for source maps is just the <code>SourceMap</code> class.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-built_in">module</span>.exports = SourceMap</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
400
docs/v1/browser-compiler/coffee-script.js
Normal file
@@ -0,0 +1,400 @@
|
||||
/**
|
||||
* CoffeeScript Compiler v1.12.5
|
||||
* http://coffeescript.org
|
||||
*
|
||||
* Copyright 2011, Jeremy Ashkenas
|
||||
* Released under the MIT License
|
||||
*/
|
||||
var $jscomp={scope:{},checkStringArgs:function(t,ua,pa){if(null==t)throw new TypeError("The 'this' value for String.prototype."+pa+" must not be null or undefined");if(ua instanceof RegExp)throw new TypeError("First argument to String.prototype."+pa+" must not be a regular expression");return t+""}};
|
||||
$jscomp.defineProperty="function"==typeof Object.defineProperties?Object.defineProperty:function(t,ua,pa){if(pa.get||pa.set)throw new TypeError("ES3 does not support getters and setters.");t!=Array.prototype&&t!=Object.prototype&&(t[ua]=pa.value)};$jscomp.getGlobal=function(t){return"undefined"!=typeof window&&window===t?t:"undefined"!=typeof global&&null!=global?global:t};$jscomp.global=$jscomp.getGlobal(this);
|
||||
$jscomp.polyfill=function(t,ua,pa,e){if(ua){pa=$jscomp.global;t=t.split(".");for(e=0;e<t.length-1;e++){var va=t[e];va in pa||(pa[va]={});pa=pa[va]}t=t[t.length-1];e=pa[t];ua=ua(e);ua!=e&&null!=ua&&$jscomp.defineProperty(pa,t,{configurable:!0,writable:!0,value:ua})}};
|
||||
$jscomp.polyfill("String.prototype.repeat",function(t){return t?t:function(t){var pa=$jscomp.checkStringArgs(this,null,"repeat");if(0>t||1342177279<t)throw new RangeError("Invalid count value");t|=0;for(var e="";t;)if(t&1&&(e+=pa),t>>>=1)pa+=pa;return e}},"es6-impl","es3");$jscomp.findInternal=function(t,ua,pa){t instanceof String&&(t=String(t));for(var e=t.length,va=0;va<e;va++){var Ba=t[va];if(ua.call(pa,Ba,va,t))return{i:va,v:Ba}}return{i:-1,v:void 0}};
|
||||
$jscomp.polyfill("Array.prototype.find",function(t){return t?t:function(t,pa){return $jscomp.findInternal(this,t,pa).v}},"es6-impl","es3");$jscomp.SYMBOL_PREFIX="jscomp_symbol_";$jscomp.initSymbol=function(){$jscomp.initSymbol=function(){};$jscomp.global.Symbol||($jscomp.global.Symbol=$jscomp.Symbol)};$jscomp.symbolCounter_=0;$jscomp.Symbol=function(t){return $jscomp.SYMBOL_PREFIX+(t||"")+$jscomp.symbolCounter_++};
|
||||
$jscomp.initSymbolIterator=function(){$jscomp.initSymbol();var t=$jscomp.global.Symbol.iterator;t||(t=$jscomp.global.Symbol.iterator=$jscomp.global.Symbol("iterator"));"function"!=typeof Array.prototype[t]&&$jscomp.defineProperty(Array.prototype,t,{configurable:!0,writable:!0,value:function(){return $jscomp.arrayIterator(this)}});$jscomp.initSymbolIterator=function(){}};
|
||||
$jscomp.arrayIterator=function(t){var ua=0;return $jscomp.iteratorPrototype(function(){return ua<t.length?{done:!1,value:t[ua++]}:{done:!0}})};$jscomp.iteratorPrototype=function(t){$jscomp.initSymbolIterator();t={next:t};t[$jscomp.global.Symbol.iterator]=function(){return this};return t};$jscomp.array=$jscomp.array||{};
|
||||
$jscomp.iteratorFromArray=function(t,ua){$jscomp.initSymbolIterator();t instanceof String&&(t+="");var pa=0,e={next:function(){if(pa<t.length){var va=pa++;return{value:ua(va,t[va]),done:!1}}e.next=function(){return{done:!0,value:void 0}};return e.next()}};e[Symbol.iterator]=function(){return e};return e};$jscomp.polyfill("Array.prototype.keys",function(t){return t?t:function(){return $jscomp.iteratorFromArray(this,function(t){return t})}},"es6-impl","es3");
|
||||
(function(t){var ua=function(){function t(e){return t[e]}t["../../package.json"]={name:"coffee-script",description:"Unfancy JavaScript",keywords:["javascript","language","coffeescript","compiler"],author:"Jeremy Ashkenas",version:"1.12.5",license:"MIT",engines:{node:"\x3e\x3d0.8.0"},directories:{lib:"./lib/coffee-script"},main:"./lib/coffee-script/coffee-script",bin:{coffee:"./bin/coffee",cake:"./bin/cake"},files:["bin","lib","register.js","repl.js"],preferGlobal:!0,scripts:{test:"node ./bin/cake test",
|
||||
"test-harmony":"node --harmony ./bin/cake test"},homepage:"http://coffeescript.org",bugs:"https://github.com/jashkenas/coffeescript/issues",repository:{type:"git",url:"git://github.com/jashkenas/coffeescript.git"},devDependencies:{docco:"~0.7.0","google-closure-compiler-js":"^20170218.0.0","highlight.js":"~9.10.0",jison:"\x3e\x3d0.4.17","markdown-it":"^8.3.1",underscore:"~1.8.3"}};t["./helpers"]=function(){var e={};(function(){var t,Ba,V,a,c,Da;e.starts=function(a,c,p){return c===a.substr(p,c.length)};
|
||||
e.ends=function(a,c,p){var g;g=c.length;return c===a.substr(a.length-g-(p||0),g)};e.repeat=c=function(a,c){var g;for(g="";0<c;)c&1&&(g+=a),c>>>=1,a+=a;return g};e.compact=function(a){var g,c,e,V;V=[];g=0;for(e=a.length;g<e;g++)(c=a[g])&&V.push(c);return V};e.count=function(a,c){var g,v;g=v=0;if(!c.length)return 1/0;for(;v=1+a.indexOf(c,v);)g++;return g};e.merge=function(a,c){return Ba(Ba({},a),c)};Ba=e.extend=function(a,c){var g,v;for(g in c)v=c[g],a[g]=v;return a};e.flatten=V=function(a){var g,c,
|
||||
e,G;c=[];e=0;for(G=a.length;e<G;e++)g=a[e],"[object Array]"===Object.prototype.toString.call(g)?c=c.concat(V(g)):c.push(g);return c};e.del=function(a,c){var g;g=a[c];delete a[c];return g};e.some=null!=(a=Array.prototype.some)?a:function(a){var g,c,e;c=0;for(e=this.length;c<e;c++)if(g=this[c],a(g))return!0;return!1};e.invertLiterate=function(a){var g;g=!0;var c,e,V,F;V=a.split("\n");F=[];c=0;for(e=V.length;c<e;c++)a=V[c],g&&/^([ ]{4}|[ ]{0,3}\t)/.test(a)?F.push(a):(g=/^\s*$/.test(a))?F.push(a):F.push("# "+
|
||||
a);return F.join("\n")};t=function(a,c){return c?{first_line:a.first_line,first_column:a.first_column,last_line:c.last_line,last_column:c.last_column}:a};e.addLocationDataFn=function(a,c){return function(g){"object"===typeof g&&g.updateLocationDataIfMissing&&g.updateLocationDataIfMissing(t(a,c));return g}};e.locationDataToString=function(a){var g;"2"in a&&"first_line"in a[2]?g=a[2]:"first_line"in a&&(g=a);return g?g.first_line+1+":"+(g.first_column+1)+"-"+(g.last_line+1+":"+(g.last_column+1)):"No location data"};
|
||||
e.baseFileName=function(a,c,e){null==c&&(c=!1);null==e&&(e=!1);a=a.split(e?/\\|\//:/\//);a=a[a.length-1];if(!(c&&0<=a.indexOf(".")))return a;a=a.split(".");a.pop();"coffee"===a[a.length-1]&&1<a.length&&a.pop();return a.join(".")};e.isCoffee=function(a){return/\.((lit)?coffee|coffee\.md)$/.test(a)};e.isLiterate=function(a){return/\.(litcoffee|coffee\.md)$/.test(a)};e.throwSyntaxError=function(a,c){a=new SyntaxError(a);a.location=c;a.toString=Da;a.stack=a.toString();throw a;};e.updateSyntaxError=function(a,
|
||||
c,e){a.toString===Da&&(a.code||(a.code=c),a.filename||(a.filename=e),a.stack=a.toString());return a};Da=function(){var a,e,p,V,G,F,x,w,K,t;if(!this.code||!this.location)return Error.prototype.toString.call(this);a=this.location;F=a.first_line;G=a.first_column;p=a.last_line;x=a.last_column;null==p&&(p=F);null==x&&(x=G);V=this.filename||"[stdin]";a=this.code.split("\n")[F];p=F===p?x+1:a.length;x=a.slice(0,G).replace(/[^\s]/g," ")+c("^",p-G);"undefined"!==typeof process&&null!==process&&(e=(null!=(w=
|
||||
process.stdout)?w.isTTY:void 0)&&!(null!=(K=process.env)&&K.NODE_DISABLE_COLORS));if(null!=(t=this.colorful)?t:e)e=function(a){return"\u001b[1;31m"+a+"\u001b[0m"},a=a.slice(0,G)+e(a.slice(G,p))+a.slice(p),x=e(x);return V+":"+(F+1)+":"+(G+1)+": error: "+this.message+"\n"+a+"\n"+x};e.nameWhitespaceCharacter=function(a){switch(a){case " ":return"space";case "\n":return"newline";case "\r":return"carriage return";case "\t":return"tab";default:return a}}}).call(this);return e}();t["./rewriter"]=function(){var e=
|
||||
{};(function(){var t,Ba,V,a,c,Da,g,v,p,l,G,F,x,w,K,M,I,z,E=[].indexOf||function(a){for(var c=0,g=this.length;c<g;c++)if(c in this&&this[c]===a)return c;return-1},N=[].slice;w=function(a,c,g){a=[a,c];a.generated=!0;g&&(a.origin=g);return a};e.Rewriter=function(){function k(){}k.prototype.rewrite=function(a){this.tokens=a;this.removeLeadingNewlines();this.closeOpenCalls();this.closeOpenIndexes();this.normalizeLines();this.tagPostfixConditionals();this.addImplicitBracesAndParens();this.addLocationDataToGeneratedTokens();
|
||||
this.fixOutdentLocationData();return this.tokens};k.prototype.scanTokens=function(a){var c,m,h;h=this.tokens;for(c=0;m=h[c];)c+=a.call(this,m,c,h);return!0};k.prototype.detectEnd=function(m,g,r){var h,q,k,e,B;B=this.tokens;for(h=0;e=B[m];){if(0===h&&g.call(this,e,m))return r.call(this,e,m);if(!e||0>h)return r.call(this,e,m-1);(q=e[0],0<=E.call(c,q))?h+=1:(k=e[0],0<=E.call(a,k))&&--h;m+=1}return m-1};k.prototype.removeLeadingNewlines=function(){var a,c,g,h,y;h=this.tokens;a=c=0;for(g=h.length;c<g&&
|
||||
(y=h[a][0],"TERMINATOR"===y);a=++c);if(a)return this.tokens.splice(0,a)};k.prototype.closeOpenCalls=function(){var a,c;c=function(a,c){var h;return")"===(h=a[0])||"CALL_END"===h||"OUTDENT"===a[0]&&")"===this.tag(c-1)};a=function(a,c){return this.tokens["OUTDENT"===a[0]?c-1:c][0]="CALL_END"};return this.scanTokens(function(g,h){"CALL_START"===g[0]&&this.detectEnd(h+1,c,a);return 1})};k.prototype.closeOpenIndexes=function(){var a,c;c=function(a,c){var h;return"]"===(h=a[0])||"INDEX_END"===h};a=function(a,
|
||||
c){return a[0]="INDEX_END"};return this.scanTokens(function(g,h){"INDEX_START"===g[0]&&this.detectEnd(h+1,c,a);return 1})};k.prototype.indexOfTag=function(){var a,c,g,h,e,k,u;c=arguments[0];e=2<=arguments.length?N.call(arguments,1):[];g=h=a=0;for(k=e.length;0<=k?h<k:h>k;g=0<=k?++h:--h){for(;"HERECOMMENT"===this.tag(c+g+a);)a+=2;if(null!=e[g]&&("string"===typeof e[g]&&(e[g]=[e[g]]),u=this.tag(c+g+a),0>E.call(e[g],u)))return-1}return c+g+a-1};k.prototype.looksObjectish=function(g){var m;if(-1<this.indexOfTag(g,
|
||||
"@",null,":")||-1<this.indexOfTag(g,null,":"))return!0;g=this.indexOfTag(g,c);return-1<g&&(m=null,this.detectEnd(g+1,function(c){var h;return h=c[0],0<=E.call(a,h)},function(a,c){return m=c}),":"===this.tag(m+1))?!0:!1};k.prototype.findTagsBackwards=function(g,e){var m,h,k,q,u,B,p;for(m=[];0<=g&&(m.length||(q=this.tag(g),0>E.call(e,q))&&((u=this.tag(g),0>E.call(c,u))||this.tokens[g].generated)&&(B=this.tag(g),0>E.call(G,B)));)(h=this.tag(g),0<=E.call(a,h))&&m.push(this.tag(g)),(k=this.tag(g),0<=E.call(c,
|
||||
k))&&m.length&&m.pop(),--g;return p=this.tag(g),0<=E.call(e,p)};k.prototype.addImplicitBracesAndParens=function(){var m,e;m=[];e=null;return this.scanTokens(function(k,h,q){var r,u,y,V,z,H,l,x,C,A,t,D,K,F,I,M,N,J;J=k[0];A=(t=0<h?q[h-1]:[])[0];C=(h<q.length-1?q[h+1]:[])[0];I=function(){return m[m.length-1]};M=h;y=function(a){return h-M+a};V=function(){var a,c;return null!=(a=I())?null!=(c=a[2])?c.ours:void 0:void 0};z=function(){var a;return V()&&"("===(null!=(a=I())?a[0]:void 0)};l=function(){var a;
|
||||
return V()&&"{"===(null!=(a=I())?a[0]:void 0)};H=function(){var a;return V&&"CONTROL"===(null!=(a=I())?a[0]:void 0)};N=function(a){var c;c=null!=a?a:h;m.push(["(",c,{ours:!0}]);q.splice(c,0,w("CALL_START","("));if(null==a)return h+=1};r=function(){m.pop();q.splice(h,0,w("CALL_END",")",["","end of input",k[2]]));return h+=1};x=function(a,c){var g;null==c&&(c=!0);g=null!=a?a:h;m.push(["{",g,{sameLine:!0,startsLine:c,ours:!0}]);c=new String("{");c.generated=!0;q.splice(g,0,w("{",c,k));if(null==a)return h+=
|
||||
1};u=function(a){a=null!=a?a:h;m.pop();q.splice(a,0,w("}","}",k));return h+=1};if(z()&&("IF"===J||"TRY"===J||"FINALLY"===J||"CATCH"===J||"CLASS"===J||"SWITCH"===J))return m.push(["CONTROL",h,{ours:!0}]),y(1);if("INDENT"===J&&V()){if("\x3d\x3e"!==A&&"-\x3e"!==A&&"["!==A&&"("!==A&&","!==A&&"{"!==A&&"TRY"!==A&&"ELSE"!==A&&"\x3d"!==A)for(;z();)r();H()&&m.pop();m.push([J,h]);return y(1)}if(0<=E.call(c,J))return m.push([J,h]),y(1);if(0<=E.call(a,J)){for(;V();)z()?r():l()?u():m.pop();e=m.pop()}if((0<=E.call(v,
|
||||
J)&&k.spaced||"?"===J&&0<h&&!q[h-1].spaced)&&(0<=E.call(Da,C)||0<=E.call(p,C)&&(null==(D=q[h+1])||!D.spaced)&&(null==(K=q[h+1])||!K.newLine)))return"?"===J&&(J=k[0]="FUNC_EXIST"),N(h+1),y(2);if(0<=E.call(v,J)&&-1<this.indexOfTag(h+1,"INDENT")&&this.looksObjectish(h+2)&&!this.findTagsBackwards(h,"CLASS EXTENDS IF CATCH SWITCH LEADING_WHEN FOR WHILE UNTIL".split(" ")))return N(h+1),m.push(["INDENT",h+2]),y(3);if(":"===J){for(u=function(){var c;switch(!1){case c=this.tag(h-1),0>E.call(a,c):return e[1];
|
||||
case "@"!==this.tag(h-2):return h-2;default:return h-1}}.call(this);"HERECOMMENT"===this.tag(u-2);)u-=2;this.insideForDeclaration="FOR"===C;H=0===u||(F=this.tag(u-1),0<=E.call(G,F))||q[u-1].newLine;if(I()&&(l=I(),F=l[0],t=l[1],("{"===F||"INDENT"===F&&"{"===this.tag(t-1))&&(H||","===this.tag(u-1)||"{"===this.tag(u-1))))return y(1);x(u,!!H);return y(2)}l()&&0<=E.call(G,J)&&(I()[2].sameLine=!1);x="OUTDENT"===A||t.newLine;if(0<=E.call(g,J)||0<=E.call(Ba,J)&&x)for(;V();)if(x=I(),F=x[0],t=x[1],F=x[2],x=
|
||||
F.sameLine,H=F.startsLine,z()&&","!==A)r();else if(l()&&!this.insideForDeclaration&&x&&"TERMINATOR"!==J&&":"!==A)u();else if(!l()||"TERMINATOR"!==J||","===A||H&&this.looksObjectish(h+1))break;else{if("HERECOMMENT"===C)return y(1);u()}if(!(","!==J||this.looksObjectish(h+1)||!l()||this.insideForDeclaration||"TERMINATOR"===C&&this.looksObjectish(h+2)))for(C="OUTDENT"===C?1:0;l();)u(h+C);return y(1)})};k.prototype.addLocationDataToGeneratedTokens=function(){return this.scanTokens(function(a,c,g){var h,
|
||||
m,k;if(a[2]||!a.generated&&!a.explicit)return 1;"{"===a[0]&&(h=null!=(k=g[c+1])?k[2]:void 0)?(m=h.first_line,h=h.first_column):(h=null!=(m=g[c-1])?m[2]:void 0)?(m=h.last_line,h=h.last_column):m=h=0;a[2]={first_line:m,first_column:h,last_line:m,last_column:h};return 1})};k.prototype.fixOutdentLocationData=function(){return this.scanTokens(function(a,c,g){if(!("OUTDENT"===a[0]||a.generated&&"CALL_END"===a[0]||a.generated&&"}"===a[0]))return 1;c=g[c-1][2];a[2]={first_line:c.last_line,first_column:c.last_column,
|
||||
last_line:c.last_line,last_column:c.last_column};return 1})};k.prototype.normalizeLines=function(){var a,c,g,h,k;k=g=h=null;c=function(a,c){var g,h,m,e;return";"!==a[1]&&(g=a[0],0<=E.call(F,g))&&!("TERMINATOR"===a[0]&&(h=this.tag(c+1),0<=E.call(V,h)))&&!("ELSE"===a[0]&&"THEN"!==k)&&!!("CATCH"!==(m=a[0])&&"FINALLY"!==m||"-\x3e"!==k&&"\x3d\x3e"!==k)||(e=a[0],0<=E.call(Ba,e))&&this.tokens[c-1].newLine};a=function(a,c){return this.tokens.splice(","===this.tag(c-1)?c-1:c,0,h)};return this.scanTokens(function(m,
|
||||
e,q){var r,y,p;m=m[0];if("TERMINATOR"===m){if("ELSE"===this.tag(e+1)&&"OUTDENT"!==this.tag(e-1))return q.splice.apply(q,[e,1].concat(N.call(this.indentation()))),1;if(r=this.tag(e+1),0<=E.call(V,r))return q.splice(e,1),0}if("CATCH"===m)for(r=y=1;2>=y;r=++y)if("OUTDENT"===(p=this.tag(e+r))||"TERMINATOR"===p||"FINALLY"===p)return q.splice.apply(q,[e+r,0].concat(N.call(this.indentation()))),2+r;0<=E.call(x,m)&&"INDENT"!==this.tag(e+1)&&("ELSE"!==m||"IF"!==this.tag(e+1))&&(k=m,p=this.indentation(q[e]),
|
||||
g=p[0],h=p[1],"THEN"===k&&(g.fromThen=!0),q.splice(e+1,0,g),this.detectEnd(e+2,c,a),"THEN"===m&&q.splice(e,1));return 1})};k.prototype.tagPostfixConditionals=function(){var a,c,g;g=null;c=function(a,c){a=a[0];c=this.tokens[c-1][0];return"TERMINATOR"===a||"INDENT"===a&&0>E.call(x,c)};a=function(a,c){if("INDENT"!==a[0]||a.generated&&!a.fromThen)return g[0]="POST_"+g[0]};return this.scanTokens(function(h,m){if("IF"!==h[0])return 1;g=h;this.detectEnd(m+1,c,a);return 1})};k.prototype.indentation=function(a){var c,
|
||||
g;c=["INDENT",2];g=["OUTDENT",2];a?(c.generated=g.generated=!0,c.origin=g.origin=a):c.explicit=g.explicit=!0;return[c,g]};k.prototype.generate=w;k.prototype.tag=function(a){var c;return null!=(c=this.tokens[a])?c[0]:void 0};return k}();t=[["(",")"],["[","]"],["{","}"],["INDENT","OUTDENT"],["CALL_START","CALL_END"],["PARAM_START","PARAM_END"],["INDEX_START","INDEX_END"],["STRING_START","STRING_END"],["REGEX_START","REGEX_END"]];e.INVERSES=l={};c=[];a=[];K=0;for(I=t.length;K<I;K++)z=t[K],M=z[0],z=z[1],
|
||||
c.push(l[z]=M),a.push(l[M]=z);V=["CATCH","THEN","ELSE","FINALLY"].concat(a);v="IDENTIFIER PROPERTY SUPER ) CALL_END ] INDEX_END @ THIS".split(" ");Da="IDENTIFIER PROPERTY NUMBER INFINITY NAN STRING STRING_START REGEX REGEX_START JS NEW PARAM_START CLASS IF TRY SWITCH THIS UNDEFINED NULL BOOL UNARY YIELD UNARY_MATH SUPER THROW @ -\x3e \x3d\x3e [ ( { -- ++".split(" ");p=["+","-"];g="POST_IF FOR WHILE UNTIL WHEN BY LOOP TERMINATOR".split(" ");x="ELSE -\x3e \x3d\x3e TRY FINALLY THEN".split(" ");F="TERMINATOR CATCH FINALLY ELSE OUTDENT LEADING_WHEN".split(" ");
|
||||
G=["TERMINATOR","INDENT","OUTDENT"];Ba=[".","?.","::","?::"]}).call(this);return e}();t["./lexer"]=function(){var e={};(function(){var va,Ba,V,a,c,Da,g,v,p,l,G,F,x,w,K,M,I,z,E,N,k,m,q,r,h,y,O,u,B,T,S,H,ba,R,C,A,W,D,P,Y,Z,U,aa,J,ca,Q,pa,ua,Ua,ja,da,ea,ha,ia,ka,la,L,fa,qa,ra,X=[].indexOf||function(a){for(var c=0,g=this.length;c<g;c++)if(c in this&&this[c]===a)return c;return-1},sa=[].slice;fa=t("./rewriter");D=fa.Rewriter;N=fa.INVERSES;fa=t("./helpers");ha=fa.count;qa=fa.repeat;ia=fa.invertLiterate;
|
||||
ra=fa.throwSyntaxError;e.Lexer=function(){function e(){}e.prototype.tokenize=function(a,c){var g,h,e,Ca;null==c&&(c={});this.literate=c.literate;this.outdebt=this.indebt=this.baseIndent=this.indent=0;this.indents=[];this.ends=[];this.tokens=[];this.exportSpecifierList=this.importSpecifierList=this.seenExport=this.seenImport=this.seenFor=!1;this.chunkLine=c.line||0;this.chunkColumn=c.column||0;a=this.clean(a);for(e=0;this.chunk=a.slice(e);)if(g=this.identifierToken()||this.commentToken()||this.whitespaceToken()||
|
||||
this.lineToken()||this.stringToken()||this.numberToken()||this.regexToken()||this.jsToken()||this.literalToken(),Ca=this.getLineAndColumnFromChunk(g),this.chunkLine=Ca[0],this.chunkColumn=Ca[1],e+=g,c.untilBalanced&&0===this.ends.length)return{tokens:this.tokens,index:e};this.closeIndentation();(h=this.ends.pop())&&this.error("missing "+h.tag,h.origin[2]);return!1===c.rewrite?this.tokens:(new D).rewrite(this.tokens)};e.prototype.clean=function(a){a.charCodeAt(0)===va&&(a=a.slice(1));a=a.replace(/\r/g,
|
||||
"").replace(ua,"");ea.test(a)&&(a="\n"+a,this.chunkLine--);this.literate&&(a=ia(a));return a};e.prototype.identifierToken=function(){var g,h,e,k,q,y,p,u,V,w,z,B,l;if(!(h=I.exec(this.chunk)))return 0;q=h[0];e=h[1];h=h[2];k=e.length;y=void 0;if("own"===e&&"FOR"===this.tag())return this.token("OWN",e),e.length;if("from"===e&&"YIELD"===this.tag())return this.token("FROM",e),e.length;if("as"===e&&this.seenImport){if("*"===this.value())this.tokens[this.tokens.length-1][0]="IMPORT_ALL";else if(p=this.value(),
|
||||
0<=X.call(Da,p))this.tokens[this.tokens.length-1][0]="IDENTIFIER";if("DEFAULT"===(u=this.tag())||"IMPORT_ALL"===u||"IDENTIFIER"===u)return this.token("AS",e),e.length}if("as"===e&&this.seenExport&&("IDENTIFIER"===(V=this.tag())||"DEFAULT"===V))return this.token("AS",e),e.length;if("default"===e&&this.seenExport&&("EXPORT"===(w=this.tag())||"AS"===w))return this.token("DEFAULT",e),e.length;p=this.tokens;p=p[p.length-1];l=h||null!=p&&("."===(z=p[0])||"?."===z||"::"===z||"?::"===z||!p.spaced&&"@"===
|
||||
p[0])?"PROPERTY":"IDENTIFIER";"IDENTIFIER"!==l||!(0<=X.call(m,e)||0<=X.call(Da,e))||this.exportSpecifierList&&0<=X.call(Da,e)?"IDENTIFIER"===l&&this.seenFor&&"from"===e&&ka(p)&&(l="FORFROM",this.seenFor=!1):(l=e.toUpperCase(),"WHEN"===l&&(B=this.tag(),0<=X.call(r,B))?l="LEADING_WHEN":"FOR"===l?this.seenFor=!0:"UNLESS"===l?l="IF":"IMPORT"===l?this.seenImport=!0:"EXPORT"===l?this.seenExport=!0:0<=X.call(Ua,l)?l="UNARY":0<=X.call(A,l)&&("INSTANCEOF"!==l&&this.seenFor?(l="FOR"+l,this.seenFor=!1):(l="RELATION",
|
||||
"!"===this.value()&&(y=this.tokens.pop(),e="!"+e))));"IDENTIFIER"===l&&0<=X.call(W,e)&&this.error("reserved word '"+e+"'",{length:e.length});"PROPERTY"!==l&&(0<=X.call(a,e)&&(g=e,e=c[e]),l=function(){switch(e){case "!":return"UNARY";case "\x3d\x3d":case "!\x3d":return"COMPARE";case "true":case "false":return"BOOL";case "break":case "continue":case "debugger":return"STATEMENT";case "\x26\x26":case "||":return e;default:return l}}());z=this.token(l,e,0,k);g&&(z.origin=[l,g,z[2]]);y&&(g=[y[2].first_line,
|
||||
y[2].first_column],z[2].first_line=g[0],z[2].first_column=g[1]);h&&(g=q.lastIndexOf(":"),this.token(":",":",g,h.length));return q.length};e.prototype.numberToken=function(){var a,c,g,e;if(!(c=B.exec(this.chunk)))return 0;g=c[0];c=g.length;switch(!1){case !/^0[BOX]/.test(g):this.error("radix prefix in '"+g+"' must be lowercase",{offset:1});break;case !/^(?!0x).*E/.test(g):this.error("exponential notation in '"+g+"' must be indicated with a lowercase 'e'",{offset:g.indexOf("E")});break;case !/^0\d*[89]/.test(g):this.error("decimal literal '"+
|
||||
g+"' must not be prefixed with '0'",{length:c});break;case !/^0\d+/.test(g):this.error("octal literal '"+g+"' must be prefixed with '0o'",{length:c})}a=function(){switch(g.charAt(1)){case "b":return 2;case "o":return 8;case "x":return 16;default:return null}}();a=null!=a?parseInt(g.slice(2),a):parseFloat(g);if("b"===(e=g.charAt(1))||"o"===e)g="0x"+a.toString(16);this.token(Infinity===a?"INFINITY":"NUMBER",g,0,c);return c};e.prototype.stringToken=function(){var a,c,g,e,h,m,k,r,p,y,l,u;p=(Q.exec(this.chunk)||
|
||||
[])[0];if(!p)return 0;this.tokens.length&&"from"===this.value()&&(this.seenImport||this.seenExport)&&(this.tokens[this.tokens.length-1][0]="FROM");g=function(){switch(p){case "'":return ca;case '"':return U;case "'''":return x;case '"""':return G}}();e=3===p.length;g=this.matchWithInterpolations(g,p);u=g.tokens;h=g.index;a=u.length-1;g=p.charAt(0);if(e){k=null;for(e=function(){var a,c,g;g=[];m=a=0;for(c=u.length;a<c;m=++a)l=u[m],"NEOSTRING"===l[0]&&g.push(l[1]);return g}().join("#{}");c=F.exec(e);)if(c=
|
||||
c[1],null===k||0<(y=c.length)&&y<k.length)k=c;k&&(r=RegExp("\\n"+k,"g"));this.mergeInterpolationTokens(u,{delimiter:g},function(c){return function(g,e){g=c.formatString(g);r&&(g=g.replace(r,"\n"));0===e&&(g=g.replace(q,""));e===a&&(g=g.replace(pa,""));return g}}(this))}else this.mergeInterpolationTokens(u,{delimiter:g},function(c){return function(g,e){g=c.formatString(g);return g=g.replace(Y,function(c,b){return 0===e&&0===b||e===a&&b+c.length===g.length?"":" "})}}(this));return h};e.prototype.commentToken=
|
||||
function(){var a,c,e;if(!(e=this.chunk.match(g)))return 0;a=e[0];if(c=e[1])(e=l.exec(a))&&this.error("block comments cannot contain "+e[0],{offset:e.index,length:e[0].length}),0<=c.indexOf("\n")&&(c=c.replace(RegExp("\\n"+qa(" ",this.indent),"g"),"\n")),this.token("HERECOMMENT",c,0,a.length);return a.length};e.prototype.jsToken=function(){var a,c;if("`"!==this.chunk.charAt(0)||!(a=M.exec(this.chunk)||k.exec(this.chunk)))return 0;c=a[1].replace(/\\+(`|$)/g,function(a){return a.slice(-Math.ceil(a.length/
|
||||
2))});this.token("JS",c,0,a[0].length);return a[0].length};e.prototype.regexToken=function(){var a,c,g,e,h,m,k,q;switch(!1){case !(c=R.exec(this.chunk)):this.error("regular expressions cannot begin with "+c[2],{offset:c.index+c[1].length});break;case !(c=this.matchWithInterpolations(w,"///")):q=c.tokens;h=c.index;break;case !(c=H.exec(this.chunk)):k=c[0];a=c[1];c=c[2];this.validateEscapes(a,{isRegex:!0,offsetInChunk:1});h=k.length;m=this.tokens;if(m=m[m.length-1])if(m.spaced&&(g=m[0],0<=X.call(Ba,
|
||||
g))){if(!c||S.test(k))return 0}else if(e=m[0],0<=X.call(u,e))return 0;c||this.error("missing / (unclosed regex)");break;default:return 0}e=ba.exec(this.chunk.slice(h))[0];g=h+e.length;c=this.makeToken("REGEX",null,0,g);switch(!1){case !!da.test(e):this.error("invalid regular expression flags "+e,{offset:h,length:e.length});break;case !(k||1===q.length):null==a&&(a=this.formatHeregex(q[0][1]));this.token("REGEX",""+this.makeDelimitedLiteral(a,{delimiter:"/"})+e,0,g,c);break;default:this.token("REGEX_START",
|
||||
"(",0,0,c),this.token("IDENTIFIER","RegExp",0,0),this.token("CALL_START","(",0,0),this.mergeInterpolationTokens(q,{delimiter:'"',double:!0},this.formatHeregex),e&&(this.token(",",",",h-1,0),this.token("STRING",'"'+e+'"',h-1,e.length)),this.token(")",")",g-1,0),this.token("REGEX_END",")",g-1,0)}return g};e.prototype.lineToken=function(){var a,c,g;if(!(c=O.exec(this.chunk)))return 0;c=c[0];this.seenFor=!1;this.importSpecifierList||(this.seenImport=!1);this.exportSpecifierList||(this.seenExport=!1);
|
||||
g=c.length-1-c.lastIndexOf("\n");a=this.unfinished();if(g-this.indebt===this.indent)return a?this.suppressNewlines():this.newlineToken(0),c.length;if(g>this.indent){if(a)return this.indebt=g-this.indent,this.suppressNewlines(),c.length;if(!this.tokens.length)return this.baseIndent=this.indent=g,c.length;a=g-this.indent+this.outdebt;this.token("INDENT",a,c.length-g,g);this.indents.push(a);this.ends.push({tag:"OUTDENT"});this.outdebt=this.indebt=0;this.indent=g}else g<this.baseIndent?this.error("missing indentation",
|
||||
{offset:c.length}):(this.indebt=0,this.outdentToken(this.indent-g,a,c.length));return c.length};e.prototype.outdentToken=function(a,c,g){var e,h,m,k;for(e=this.indent-a;0<a;)(m=this.indents[this.indents.length-1])?m===this.outdebt?(a-=this.outdebt,this.outdebt=0):m<this.outdebt?(this.outdebt-=m,a-=m):(h=this.indents.pop()+this.outdebt,g&&(k=this.chunk[g],0<=X.call(z,k))&&(e-=h-a,a=h),this.outdebt=0,this.pair("OUTDENT"),this.token("OUTDENT",a,0,g),a-=h):a=0;h&&(this.outdebt-=a);for(;";"===this.value();)this.tokens.pop();
|
||||
"TERMINATOR"===this.tag()||c||this.token("TERMINATOR","\n",g,0);this.indent=e;return this};e.prototype.whitespaceToken=function(){var a,c;if(!(a=ea.exec(this.chunk))&&"\n"!==this.chunk.charAt(0))return 0;c=this.tokens;(c=c[c.length-1])&&(c[a?"spaced":"newLine"]=!0);return a?a[0].length:0};e.prototype.newlineToken=function(a){for(;";"===this.value();)this.tokens.pop();"TERMINATOR"!==this.tag()&&this.token("TERMINATOR","\n",a,0);return this};e.prototype.suppressNewlines=function(){"\\"===this.value()&&
|
||||
this.tokens.pop();return this};e.prototype.literalToken=function(){var a,c,g,e,h,m,k,q;(a=T.exec(this.chunk))?(a=a[0],V.test(a)&&this.tagParameters()):a=this.chunk.charAt(0);q=a;e=this.tokens;if((e=e[e.length-1])&&0<=X.call(["\x3d"].concat(sa.call(p)),a)&&(k=!1,"\x3d"!==a||"||"!==(g=e[1])&&"\x26\x26"!==g||e.spaced||(e[0]="COMPOUND_ASSIGN",e[1]+="\x3d",e=this.tokens[this.tokens.length-2],k=!0),e&&"PROPERTY"!==e[0]&&(g=null!=(c=e.origin)?c:e,(c=la(e[1],g[1]))&&this.error(c,g[2])),k))return a.length;
|
||||
"{"===a&&this.seenImport?this.importSpecifierList=!0:this.importSpecifierList&&"}"===a?this.importSpecifierList=!1:"{"===a&&"EXPORT"===(null!=e?e[0]:void 0)?this.exportSpecifierList=!0:this.exportSpecifierList&&"}"===a&&(this.exportSpecifierList=!1);if(";"===a)this.seenFor=this.seenImport=this.seenExport=!1,q="TERMINATOR";else if("*"===a&&"EXPORT"===e[0])q="EXPORT_ALL";else if(0<=X.call(y,a))q="MATH";else if(0<=X.call(v,a))q="COMPARE";else if(0<=X.call(p,a))q="COMPOUND_ASSIGN";else if(0<=X.call(Ua,
|
||||
a))q="UNARY";else if(0<=X.call(ja,a))q="UNARY_MATH";else if(0<=X.call(P,a))q="SHIFT";else if("?"===a&&null!=e&&e.spaced)q="BIN?";else if(e&&!e.spaced)if("("===a&&(h=e[0],0<=X.call(Ba,h)))"?"===e[0]&&(e[0]="FUNC_EXIST"),q="CALL_START";else if("["===a&&(m=e[0],0<=X.call(E,m)))switch(q="INDEX_START",e[0]){case "?":e[0]="INDEX_SOAK"}h=this.makeToken(q,a);switch(a){case "(":case "{":case "[":this.ends.push({tag:N[a],origin:h});break;case ")":case "}":case "]":this.pair(a)}this.tokens.push(h);return a.length};
|
||||
e.prototype.tagParameters=function(){var a,c,g,e;if(")"!==this.tag())return this;c=[];e=this.tokens;a=e.length;for(e[--a][0]="PARAM_END";g=e[--a];)switch(g[0]){case ")":c.push(g);break;case "(":case "CALL_START":if(c.length)c.pop();else return"("===g[0]&&(g[0]="PARAM_START"),this}return this};e.prototype.closeIndentation=function(){return this.outdentToken(this.indent)};e.prototype.matchWithInterpolations=function(a,c){var g,h,m,k,q,p,r,y;y=[];q=c.length;if(this.chunk.slice(0,q)!==c)return null;for(r=
|
||||
this.chunk.slice(q);;){k=a.exec(r)[0];this.validateEscapes(k,{isRegex:"/"===c.charAt(0),offsetInChunk:q});y.push(this.makeToken("NEOSTRING",k,q));r=r.slice(k.length);q+=k.length;if("#{"!==r.slice(0,2))break;g=this.getLineAndColumnFromChunk(q+1);k=g[0];g=g[1];g=(new e).tokenize(r.slice(1),{line:k,column:g,untilBalanced:!0});k=g.tokens;h=g.index;h+=1;p=k[0];g=k[k.length-1];p[0]=p[1]="(";g[0]=g[1]=")";g.origin=["","end of interpolation",g[2]];"TERMINATOR"===(null!=(m=k[1])?m[0]:void 0)&&k.splice(1,1);
|
||||
y.push(["TOKENS",k]);r=r.slice(h);q+=h}r.slice(0,c.length)!==c&&this.error("missing "+c,{length:c.length});a=y[0];m=y[y.length-1];a[2].first_column-=c.length;"\n"===m[1].substr(-1)?(m[2].last_line+=1,m[2].last_column=c.length-1):m[2].last_column+=c.length;0===m[1].length&&--m[2].last_column;return{tokens:y,index:q+c.length}};e.prototype.mergeInterpolationTokens=function(a,c,g){var e,h,m,k,q,r,p,y,l,u,V,z;1<a.length&&(y=this.token("STRING_START","(",0,0));m=this.tokens.length;k=q=0;for(r=a.length;q<
|
||||
r;k=++q){u=a[k];e=u[0];z=u[1];switch(e){case "TOKENS":if(2===z.length)continue;p=z[0];V=z;break;case "NEOSTRING":e=g(u[1],k);if(0===e.length)if(0===k)h=this.tokens.length;else continue;2===k&&null!=h&&this.tokens.splice(h,2);u[0]="STRING";u[1]=this.makeDelimitedLiteral(e,c);p=u;V=[u]}this.tokens.length>m&&(k=this.token("+","+"),k[2]={first_line:p[2].first_line,first_column:p[2].first_column,last_line:p[2].first_line,last_column:p[2].first_column});(l=this.tokens).push.apply(l,V)}if(y)return a=a[a.length-
|
||||
1],y.origin=["STRING",null,{first_line:y[2].first_line,first_column:y[2].first_column,last_line:a[2].last_line,last_column:a[2].last_column}],y=this.token("STRING_END",")"),y[2]={first_line:a[2].last_line,first_column:a[2].last_column,last_line:a[2].last_line,last_column:a[2].last_column}};e.prototype.pair=function(a){var c;c=this.ends;c=c[c.length-1];return a!==(c=null!=c?c.tag:void 0)?("OUTDENT"!==c&&this.error("unmatched "+a),c=this.indents,c=c[c.length-1],this.outdentToken(c,!0),this.pair(a)):
|
||||
this.ends.pop()};e.prototype.getLineAndColumnFromChunk=function(a){var c,g;if(0===a)return[this.chunkLine,this.chunkColumn];g=a>=this.chunk.length?this.chunk:this.chunk.slice(0,+(a-1)+1||9E9);a=ha(g,"\n");c=this.chunkColumn;0<a?(c=g.split("\n"),c=c[c.length-1],c=c.length):c+=g.length;return[this.chunkLine+a,c]};e.prototype.makeToken=function(a,c,g,e){var h,k;null==g&&(g=0);null==e&&(e=c.length);h={};k=this.getLineAndColumnFromChunk(g);h.first_line=k[0];h.first_column=k[1];g=this.getLineAndColumnFromChunk(g+
|
||||
(0<e?e-1:0));h.last_line=g[0];h.last_column=g[1];return[a,c,h]};e.prototype.token=function(a,c,g,e,h){a=this.makeToken(a,c,g,e);h&&(a.origin=h);this.tokens.push(a);return a};e.prototype.tag=function(){var a;a=this.tokens;a=a[a.length-1];return null!=a?a[0]:void 0};e.prototype.value=function(){var a;a=this.tokens;a=a[a.length-1];return null!=a?a[1]:void 0};e.prototype.unfinished=function(){var a;return h.test(this.chunk)||"\\"===(a=this.tag())||"."===a||"?."===a||"?::"===a||"UNARY"===a||"MATH"===a||
|
||||
"UNARY_MATH"===a||"+"===a||"-"===a||"**"===a||"SHIFT"===a||"RELATION"===a||"COMPARE"===a||"\x26"===a||"^"===a||"|"===a||"\x26\x26"===a||"||"===a||"BIN?"===a||"THROW"===a||"EXTENDS"===a};e.prototype.formatString=function(a){return a.replace(J,"$1")};e.prototype.formatHeregex=function(a){return a.replace(K,"$1$2")};e.prototype.validateEscapes=function(a,c){var g,e,h,k,m;null==c&&(c={});if(e=(c.isRegex?C:aa).exec(a))return e[0],a=e[1],h=e[2],g=e[3],m=e[4],g="\\"+(h||g||m),this.error((h?"octal escape sequences are not allowed":
|
||||
"invalid escape sequence")+" "+g,{offset:(null!=(k=c.offsetInChunk)?k:0)+e.index+a.length,length:g.length})};e.prototype.makeDelimitedLiteral=function(a,c){null==c&&(c={});""===a&&"/"===c.delimiter&&(a="(?:)");a=a.replace(RegExp("(\\\\\\\\)|(\\\\0(?\x3d[1-7]))|\\\\?("+c.delimiter+")|\\\\?(?:(\\n)|(\\r)|(\\u2028)|(\\u2029))|(\\\\.)","g"),function(a,g,e,h,k,m,q,r,p){switch(!1){case !g:return c.double?g+g:g;case !e:return"\\x00";case !h:return"\\"+h;case !k:return"\\n";case !m:return"\\r";case !q:return"\\u2028";
|
||||
case !r:return"\\u2029";case !p:return c.double?"\\"+p:p}});return""+c.delimiter+a+c.delimiter};e.prototype.error=function(a,c){var g,e,h,k,m;null==c&&(c={});c="first_line"in c?c:(k=this.getLineAndColumnFromChunk(null!=(h=c.offset)?h:0),e=k[0],g=k[1],k,{first_line:e,first_column:g,last_column:g+(null!=(m=c.length)?m:1)-1});return ra(a,c)};return e}();la=function(a,c){null==c&&(c=a);switch(!1){case 0>X.call(sa.call(m).concat(sa.call(Da)),a):return"keyword '"+c+"' can't be assigned";case 0>X.call(Z,
|
||||
a):return"'"+c+"' can't be assigned";case 0>X.call(W,a):return"reserved word '"+c+"' can't be assigned";default:return!1}};e.isUnassignable=la;ka=function(a){var c;return"IDENTIFIER"===a[0]?("from"===a[1]&&(a[1][0]="IDENTIFIER",!0),!0):"FOR"===a[0]?!1:"{"===(c=a[1])||"["===c||","===c||":"===c?!1:!0};m="true false null this new delete typeof in instanceof return throw break continue debugger yield if else switch for while do try catch finally class extends super import export default".split(" ");Da=
|
||||
"undefined Infinity NaN then unless until loop of by when".split(" ");c={and:"\x26\x26",or:"||",is:"\x3d\x3d",isnt:"!\x3d",not:"!",yes:"true",no:"false",on:"true",off:"false"};a=function(){var a;a=[];for(L in c)a.push(L);return a}();Da=Da.concat(a);W="case function var void with const let enum native implements interface package private protected public static".split(" ");Z=["arguments","eval"];e.JS_FORBIDDEN=m.concat(W).concat(Z);va=65279;I=/^(?!\d)((?:(?!\s)[$\w\x7f-\uffff])+)([^\n\S]*:(?!:))?/;
|
||||
B=/^0b[01]+|^0o[0-7]+|^0x[\da-f]+|^\d*\.?\d+(?:e[+-]?\d+)?/i;T=/^(?:[-=]>|[-+*\/%<>&|^!?=]=|>>>=?|([-+:])\1|([&|<>*\/%])\2=?|\?(\.|::)|\.{2,3})/;ea=/^[^\n\S]+/;g=/^###([^#][\s\S]*?)(?:###[^\n\S]*|###$)|^(?:\s*#(?!##[^#]).*)+/;V=/^[-=]>/;O=/^(?:\n[^\n\S]*)+/;k=/^`(?!``)((?:[^`\\]|\\[\s\S])*)`/;M=/^```((?:[^`\\]|\\[\s\S]|`(?!``))*)```/;Q=/^(?:'''|"""|'|")/;ca=/^(?:[^\\']|\\[\s\S])*/;U=/^(?:[^\\"#]|\\[\s\S]|\#(?!\{))*/;x=/^(?:[^\\']|\\[\s\S]|'(?!''))*/;G=/^(?:[^\\"#]|\\[\s\S]|"(?!"")|\#(?!\{))*/;J=/((?:\\\\)+)|\\[^\S\n]*\n\s*/g;
|
||||
Y=/\s*\n\s*/g;F=/\n+([^\n\S]*)(?=\S)/g;H=/^\/(?!\/)((?:[^[\/\n\\]|\\[^\n]|\[(?:\\[^\n]|[^\]\n\\])*\])*)(\/)?/;ba=/^\w*/;da=/^(?!.*(.).*\1)[imgy]*$/;w=/^(?:[^\\\/#]|\\[\s\S]|\/(?!\/\/)|\#(?!\{))*/;K=/((?:\\\\)+)|\\(\s)|\s+(?:#.*)?/g;R=/^(\/|\/{3}\s*)(\*)/;S=/^\/=?\s/;l=/\*\//;h=/^\s*(?:,|\??\.(?![.\d])|::)/;aa=/((?:^|[^\\])(?:\\\\)*)\\(?:(0[0-7]|[1-7])|(x(?![\da-fA-F]{2}).{0,2})|(u(?![\da-fA-F]{4}).{0,4}))/;C=/((?:^|[^\\])(?:\\\\)*)\\(?:(0[0-7])|(x(?![\da-fA-F]{2}).{0,2})|(u(?![\da-fA-F]{4}).{0,4}))/;
|
||||
q=/^[^\n\S]*\n/;pa=/\n[^\n\S]*$/;ua=/\s+$/;p="-\x3d +\x3d /\x3d *\x3d %\x3d ||\x3d \x26\x26\x3d ?\x3d \x3c\x3c\x3d \x3e\x3e\x3d \x3e\x3e\x3e\x3d \x26\x3d ^\x3d |\x3d **\x3d //\x3d %%\x3d".split(" ");Ua=["NEW","TYPEOF","DELETE","DO"];ja=["!","~"];P=["\x3c\x3c","\x3e\x3e","\x3e\x3e\x3e"];v="\x3d\x3d !\x3d \x3c \x3e \x3c\x3d \x3e\x3d".split(" ");y=["*","/","%","//","%%"];A=["IN","OF","INSTANCEOF"];Ba="IDENTIFIER PROPERTY ) ] ? @ THIS SUPER".split(" ");E=Ba.concat("NUMBER INFINITY NAN STRING STRING_END REGEX REGEX_END BOOL NULL UNDEFINED } ::".split(" "));
|
||||
u=E.concat(["++","--"]);r=["INDENT","OUTDENT","TERMINATOR"];z=[")","}","]"]}).call(this);return e}();t["./parser"]=function(){var e={},va={exports:e},Ba=function(){function e(){this.yy={}}var a=function(a,n,oa,b){oa=oa||{};for(b=a.length;b--;oa[a[b]]=n);return oa},c=[1,22],t=[1,25],g=[1,83],v=[1,79],p=[1,84],l=[1,85],G=[1,81],F=[1,82],x=[1,56],w=[1,58],K=[1,59],M=[1,60],I=[1,61],z=[1,62],E=[1,49],N=[1,50],k=[1,32],m=[1,68],q=[1,69],r=[1,78],h=[1,47],y=[1,51],O=[1,52],u=[1,67],B=[1,65],T=[1,66],S=
|
||||
[1,64],H=[1,42],ba=[1,48],R=[1,63],C=[1,73],A=[1,74],W=[1,75],D=[1,76],P=[1,46],Y=[1,72],Z=[1,34],U=[1,35],aa=[1,36],J=[1,37],ca=[1,38],Q=[1,39],Ba=[1,86],va=[1,6,32,42,131],pa=[1,101],ja=[1,89],da=[1,88],ea=[1,87],ha=[1,90],ia=[1,91],ka=[1,92],la=[1,93],L=[1,94],fa=[1,95],qa=[1,96],ra=[1,97],X=[1,98],sa=[1,99],ma=[1,100],Ca=[1,104],ta=[1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],ua=[2,166],Ra=[1,110],Ga=[1,111],Sa=[1,
|
||||
112],Fa=[1,113],Na=[1,115],Oa=[1,116],Ka=[1,109],ya=[1,6,32,42,131,133,135,139,156],na=[2,27],ga=[1,123],Ha=[1,121],Aa=[1,6,31,32,40,41,42,65,70,73,82,83,84,85,87,89,90,94,113,114,115,120,122,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],Wa=[2,94],b=[1,6,31,32,42,46,65,70,73,82,83,84,85,87,89,90,94,113,114,115,120,122,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],n=[2,73],oa=[1,128],f=[1,133],d=[1,134],wa=[1,136],La=[1,
|
||||
6,31,32,40,41,42,55,65,70,73,82,83,84,85,87,89,90,94,113,114,115,120,122,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],xa=[2,91],Gb=[1,6,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],$a=[2,63],Hb=[1,166],ab=[1,178],Va=[1,180],Ib=[1,175],Ma=[1,182],ub=[1,184],Ia=[1,6,31,32,40,41,42,55,65,70,73,82,83,84,85,87,89,90,94,96,113,114,115,120,122,131,133,134,135,139,140,156,159,160,161,162,163,164,
|
||||
165,166,167,168,169,170,171,172,173,174,175],Jb=[2,110],Kb=[1,6,31,32,40,41,42,58,65,70,73,82,83,84,85,87,89,90,94,113,114,115,120,122,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],Lb=[1,6,31,32,40,41,42,46,58,65,70,73,82,83,84,85,87,89,90,94,113,114,115,120,122,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],Mb=[40,41,114],Nb=[1,241],vb=[1,240],Ja=[1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156],Ea=[2,
|
||||
71],Ob=[1,250],Ta=[6,31,32,65,70],hb=[6,31,32,55,65,70,73],bb=[1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,159,160,164,166,167,168,169,170,171,172,173,174],Pb=[40,41,82,83,84,85,87,90,113,114],ib=[1,269],cb=[2,62],jb=[1,279],Xa=[1,281],wb=[1,286],db=[1,288],Qb=[2,187],xb=[1,6,31,32,40,41,42,55,65,70,73,82,83,84,85,87,89,90,94,113,114,115,120,122,131,133,134,135,139,140,146,147,148,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],kb=[1,297],Pa=[6,31,32,70,115,120],
|
||||
Rb=[1,6,31,32,40,41,42,55,58,65,70,73,82,83,84,85,87,89,90,94,96,113,114,115,120,122,131,133,134,135,139,140,146,147,148,156,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175],Sb=[1,6,31,32,42,65,70,73,89,94,115,120,122,131,140,156],Ya=[1,6,31,32,42,65,70,73,89,94,115,120,122,131,134,140,156],lb=[146,147,148],mb=[70,146,147,148],nb=[6,31,94],Tb=[1,311],za=[6,31,32,70,94],Ub=[6,31,32,58,70,94],yb=[6,31,32,55,58,70,94],Vb=[1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,
|
||||
140,156,159,160,166,167,168,169,170,171,172,173,174],Wb=[12,28,34,38,40,41,44,45,48,49,50,51,52,53,61,62,63,67,68,89,92,95,97,105,112,117,118,119,125,129,130,133,135,137,139,149,155,157,158,159,160,161,162],Xb=[2,176],Qa=[6,31,32],eb=[2,72],Yb=[1,323],Zb=[1,324],$b=[1,6,31,32,42,65,70,73,89,94,115,120,122,127,128,131,133,134,135,139,140,151,153,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],ob=[32,151,153],ac=[1,6,32,42,65,70,73,89,94,115,120,122,131,134,140,156],pb=[1,350],zb=[1,356],
|
||||
Ab=[1,6,32,42,131,156],fb=[2,86],qb=[1,367],rb=[1,368],bc=[1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,151,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],Bb=[1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,135,139,140,156],cc=[1,381],dc=[1,382],Cb=[6,31,32,94],ec=[6,31,32,70],Db=[1,6,31,32,42,65,70,73,89,94,115,120,122,127,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],fc=[31,70],sb=[1,408],tb=[1,409],Eb=[1,415],Fb=[1,416],gc=
|
||||
{trace:function(){},yy:{},symbols_:{error:2,Root:3,Body:4,Line:5,TERMINATOR:6,Expression:7,Statement:8,YieldReturn:9,Return:10,Comment:11,STATEMENT:12,Import:13,Export:14,Value:15,Invocation:16,Code:17,Operation:18,Assign:19,If:20,Try:21,While:22,For:23,Switch:24,Class:25,Throw:26,Yield:27,YIELD:28,FROM:29,Block:30,INDENT:31,OUTDENT:32,Identifier:33,IDENTIFIER:34,Property:35,PROPERTY:36,AlphaNumeric:37,NUMBER:38,String:39,STRING:40,STRING_START:41,STRING_END:42,Regex:43,REGEX:44,REGEX_START:45,REGEX_END:46,
|
||||
Literal:47,JS:48,UNDEFINED:49,NULL:50,BOOL:51,INFINITY:52,NAN:53,Assignable:54,"\x3d":55,AssignObj:56,ObjAssignable:57,":":58,SimpleObjAssignable:59,ThisProperty:60,RETURN:61,HERECOMMENT:62,PARAM_START:63,ParamList:64,PARAM_END:65,FuncGlyph:66,"-\x3e":67,"\x3d\x3e":68,OptComma:69,",":70,Param:71,ParamVar:72,"...":73,Array:74,Object:75,Splat:76,SimpleAssignable:77,Accessor:78,Parenthetical:79,Range:80,This:81,".":82,"?.":83,"::":84,"?::":85,Index:86,INDEX_START:87,IndexValue:88,INDEX_END:89,INDEX_SOAK:90,
|
||||
Slice:91,"{":92,AssignList:93,"}":94,CLASS:95,EXTENDS:96,IMPORT:97,ImportDefaultSpecifier:98,ImportNamespaceSpecifier:99,ImportSpecifierList:100,ImportSpecifier:101,AS:102,DEFAULT:103,IMPORT_ALL:104,EXPORT:105,ExportSpecifierList:106,EXPORT_ALL:107,ExportSpecifier:108,OptFuncExist:109,Arguments:110,Super:111,SUPER:112,FUNC_EXIST:113,CALL_START:114,CALL_END:115,ArgList:116,THIS:117,"@":118,"[":119,"]":120,RangeDots:121,"..":122,Arg:123,SimpleArgs:124,TRY:125,Catch:126,FINALLY:127,CATCH:128,THROW:129,
|
||||
"(":130,")":131,WhileSource:132,WHILE:133,WHEN:134,UNTIL:135,Loop:136,LOOP:137,ForBody:138,FOR:139,BY:140,ForStart:141,ForSource:142,ForVariables:143,OWN:144,ForValue:145,FORIN:146,FOROF:147,FORFROM:148,SWITCH:149,Whens:150,ELSE:151,When:152,LEADING_WHEN:153,IfBlock:154,IF:155,POST_IF:156,UNARY:157,UNARY_MATH:158,"-":159,"+":160,"--":161,"++":162,"?":163,MATH:164,"**":165,SHIFT:166,COMPARE:167,"\x26":168,"^":169,"|":170,"\x26\x26":171,"||":172,"BIN?":173,RELATION:174,COMPOUND_ASSIGN:175,$accept:0,
|
||||
$end:1},terminals_:{2:"error",6:"TERMINATOR",12:"STATEMENT",28:"YIELD",29:"FROM",31:"INDENT",32:"OUTDENT",34:"IDENTIFIER",36:"PROPERTY",38:"NUMBER",40:"STRING",41:"STRING_START",42:"STRING_END",44:"REGEX",45:"REGEX_START",46:"REGEX_END",48:"JS",49:"UNDEFINED",50:"NULL",51:"BOOL",52:"INFINITY",53:"NAN",55:"\x3d",58:":",61:"RETURN",62:"HERECOMMENT",63:"PARAM_START",65:"PARAM_END",67:"-\x3e",68:"\x3d\x3e",70:",",73:"...",82:".",83:"?.",84:"::",85:"?::",87:"INDEX_START",89:"INDEX_END",90:"INDEX_SOAK",
|
||||
92:"{",94:"}",95:"CLASS",96:"EXTENDS",97:"IMPORT",102:"AS",103:"DEFAULT",104:"IMPORT_ALL",105:"EXPORT",107:"EXPORT_ALL",112:"SUPER",113:"FUNC_EXIST",114:"CALL_START",115:"CALL_END",117:"THIS",118:"@",119:"[",120:"]",122:"..",125:"TRY",127:"FINALLY",128:"CATCH",129:"THROW",130:"(",131:")",133:"WHILE",134:"WHEN",135:"UNTIL",137:"LOOP",139:"FOR",140:"BY",144:"OWN",146:"FORIN",147:"FOROF",148:"FORFROM",149:"SWITCH",151:"ELSE",153:"LEADING_WHEN",155:"IF",156:"POST_IF",157:"UNARY",158:"UNARY_MATH",159:"-",
|
||||
160:"+",161:"--",162:"++",163:"?",164:"MATH",165:"**",166:"SHIFT",167:"COMPARE",168:"\x26",169:"^",170:"|",171:"\x26\x26",172:"||",173:"BIN?",174:"RELATION",175:"COMPOUND_ASSIGN"},productions_:[0,[3,0],[3,1],[4,1],[4,3],[4,2],[5,1],[5,1],[5,1],[8,1],[8,1],[8,1],[8,1],[8,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[27,1],[27,2],[27,3],[30,2],[30,3],[33,1],[35,1],[37,1],[37,1],[39,1],[39,3],[43,1],[43,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[19,
|
||||
3],[19,4],[19,5],[56,1],[56,3],[56,5],[56,3],[56,5],[56,1],[59,1],[59,1],[59,1],[57,1],[57,1],[10,2],[10,1],[9,3],[9,2],[11,1],[17,5],[17,2],[66,1],[66,1],[69,0],[69,1],[64,0],[64,1],[64,3],[64,4],[64,6],[71,1],[71,2],[71,3],[71,1],[72,1],[72,1],[72,1],[72,1],[76,2],[77,1],[77,2],[77,2],[77,1],[54,1],[54,1],[54,1],[15,1],[15,1],[15,1],[15,1],[15,1],[78,2],[78,2],[78,2],[78,2],[78,1],[78,1],[86,3],[86,2],[88,1],[88,1],[75,4],[93,0],[93,1],[93,3],[93,4],[93,6],[25,1],[25,2],[25,3],[25,4],[25,2],[25,
|
||||
3],[25,4],[25,5],[13,2],[13,4],[13,4],[13,5],[13,7],[13,6],[13,9],[100,1],[100,3],[100,4],[100,4],[100,6],[101,1],[101,3],[101,1],[101,3],[98,1],[99,3],[14,3],[14,5],[14,2],[14,4],[14,5],[14,6],[14,3],[14,4],[14,7],[106,1],[106,3],[106,4],[106,4],[106,6],[108,1],[108,3],[108,3],[108,1],[108,3],[16,3],[16,3],[16,3],[16,1],[111,1],[111,2],[109,0],[109,1],[110,2],[110,4],[81,1],[81,1],[60,2],[74,2],[74,4],[121,1],[121,1],[80,5],[91,3],[91,2],[91,2],[91,1],[116,1],[116,3],[116,4],[116,4],[116,6],[123,
|
||||
1],[123,1],[123,1],[124,1],[124,3],[21,2],[21,3],[21,4],[21,5],[126,3],[126,3],[126,2],[26,2],[79,3],[79,5],[132,2],[132,4],[132,2],[132,4],[22,2],[22,2],[22,2],[22,1],[136,2],[136,2],[23,2],[23,2],[23,2],[138,2],[138,4],[138,2],[141,2],[141,3],[145,1],[145,1],[145,1],[145,1],[143,1],[143,3],[142,2],[142,2],[142,4],[142,4],[142,4],[142,6],[142,6],[142,2],[142,4],[24,5],[24,7],[24,4],[24,6],[150,1],[150,2],[152,3],[152,4],[154,3],[154,5],[20,1],[20,3],[20,3],[20,3],[18,2],[18,2],[18,2],[18,2],[18,
|
||||
2],[18,2],[18,2],[18,2],[18,2],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,3],[18,5],[18,4],[18,3]],performAction:function(a,n,oa,b,c,f,d){a=f.length-1;switch(c){case 1:return this.$=b.addLocationDataFn(d[a],d[a])(new b.Block);case 2:return this.$=f[a];case 3:this.$=b.addLocationDataFn(d[a],d[a])(b.Block.wrap([f[a]]));break;case 4:this.$=b.addLocationDataFn(d[a-2],d[a])(f[a-2].push(f[a]));break;case 5:this.$=f[a-1];break;case 6:case 7:case 8:case 9:case 10:case 12:case 13:case 14:case 15:case 16:case 17:case 18:case 19:case 20:case 21:case 22:case 23:case 24:case 25:case 26:case 35:case 40:case 42:case 56:case 57:case 58:case 59:case 60:case 61:case 71:case 72:case 82:case 83:case 84:case 85:case 90:case 91:case 94:case 98:case 104:case 163:case 187:case 188:case 190:case 220:case 221:case 239:case 245:this.$=
|
||||
f[a];break;case 11:this.$=b.addLocationDataFn(d[a],d[a])(new b.StatementLiteral(f[a]));break;case 27:this.$=b.addLocationDataFn(d[a],d[a])(new b.Op(f[a],new b.Value(new b.Literal(""))));break;case 28:case 249:case 250:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Op(f[a-1],f[a]));break;case 29:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Op(f[a-2].concat(f[a-1]),f[a]));break;case 30:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Block);break;case 31:case 105:this.$=b.addLocationDataFn(d[a-2],d[a])(f[a-
|
||||
1]);break;case 32:this.$=b.addLocationDataFn(d[a],d[a])(new b.IdentifierLiteral(f[a]));break;case 33:this.$=b.addLocationDataFn(d[a],d[a])(new b.PropertyName(f[a]));break;case 34:this.$=b.addLocationDataFn(d[a],d[a])(new b.NumberLiteral(f[a]));break;case 36:this.$=b.addLocationDataFn(d[a],d[a])(new b.StringLiteral(f[a]));break;case 37:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.StringWithInterpolations(f[a-1]));break;case 38:this.$=b.addLocationDataFn(d[a],d[a])(new b.RegexLiteral(f[a]));break;
|
||||
case 39:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.RegexWithInterpolations(f[a-1].args));break;case 41:this.$=b.addLocationDataFn(d[a],d[a])(new b.PassthroughLiteral(f[a]));break;case 43:this.$=b.addLocationDataFn(d[a],d[a])(new b.UndefinedLiteral);break;case 44:this.$=b.addLocationDataFn(d[a],d[a])(new b.NullLiteral);break;case 45:this.$=b.addLocationDataFn(d[a],d[a])(new b.BooleanLiteral(f[a]));break;case 46:this.$=b.addLocationDataFn(d[a],d[a])(new b.InfinityLiteral(f[a]));break;case 47:this.$=
|
||||
b.addLocationDataFn(d[a],d[a])(new b.NaNLiteral);break;case 48:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Assign(f[a-2],f[a]));break;case 49:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.Assign(f[a-3],f[a]));break;case 50:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Assign(f[a-4],f[a-1]));break;case 51:case 87:case 92:case 93:case 95:case 96:case 97:case 222:case 223:this.$=b.addLocationDataFn(d[a],d[a])(new b.Value(f[a]));break;case 52:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Assign(b.addLocationDataFn(d[a-
|
||||
2])(new b.Value(f[a-2])),f[a],"object",{operatorToken:b.addLocationDataFn(d[a-1])(new b.Literal(f[a-1]))}));break;case 53:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Assign(b.addLocationDataFn(d[a-4])(new b.Value(f[a-4])),f[a-1],"object",{operatorToken:b.addLocationDataFn(d[a-3])(new b.Literal(f[a-3]))}));break;case 54:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Assign(b.addLocationDataFn(d[a-2])(new b.Value(f[a-2])),f[a],null,{operatorToken:b.addLocationDataFn(d[a-1])(new b.Literal(f[a-1]))}));
|
||||
break;case 55:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Assign(b.addLocationDataFn(d[a-4])(new b.Value(f[a-4])),f[a-1],null,{operatorToken:b.addLocationDataFn(d[a-3])(new b.Literal(f[a-3]))}));break;case 62:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Return(f[a]));break;case 63:this.$=b.addLocationDataFn(d[a],d[a])(new b.Return);break;case 64:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.YieldReturn(f[a]));break;case 65:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.YieldReturn);break;case 66:this.$=
|
||||
b.addLocationDataFn(d[a],d[a])(new b.Comment(f[a]));break;case 67:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Code(f[a-3],f[a],f[a-1]));break;case 68:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Code([],f[a],f[a-1]));break;case 69:this.$=b.addLocationDataFn(d[a],d[a])("func");break;case 70:this.$=b.addLocationDataFn(d[a],d[a])("boundfunc");break;case 73:case 110:this.$=b.addLocationDataFn(d[a],d[a])([]);break;case 74:case 111:case 130:case 150:case 182:case 224:this.$=b.addLocationDataFn(d[a],
|
||||
d[a])([f[a]]);break;case 75:case 112:case 131:case 151:case 183:this.$=b.addLocationDataFn(d[a-2],d[a])(f[a-2].concat(f[a]));break;case 76:case 113:case 132:case 152:case 184:this.$=b.addLocationDataFn(d[a-3],d[a])(f[a-3].concat(f[a]));break;case 77:case 114:case 134:case 154:case 186:this.$=b.addLocationDataFn(d[a-5],d[a])(f[a-5].concat(f[a-2]));break;case 78:this.$=b.addLocationDataFn(d[a],d[a])(new b.Param(f[a]));break;case 79:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Param(f[a-1],null,!0));
|
||||
break;case 80:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Param(f[a-2],f[a]));break;case 81:case 189:this.$=b.addLocationDataFn(d[a],d[a])(new b.Expansion);break;case 86:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Splat(f[a-1]));break;case 88:this.$=b.addLocationDataFn(d[a-1],d[a])(f[a-1].add(f[a]));break;case 89:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Value(f[a-1],[].concat(f[a])));break;case 99:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Access(f[a]));break;case 100:this.$=b.addLocationDataFn(d[a-
|
||||
1],d[a])(new b.Access(f[a],"soak"));break;case 101:this.$=b.addLocationDataFn(d[a-1],d[a])([b.addLocationDataFn(d[a-1])(new b.Access(new b.PropertyName("prototype"))),b.addLocationDataFn(d[a])(new b.Access(f[a]))]);break;case 102:this.$=b.addLocationDataFn(d[a-1],d[a])([b.addLocationDataFn(d[a-1])(new b.Access(new b.PropertyName("prototype"),"soak")),b.addLocationDataFn(d[a])(new b.Access(f[a]))]);break;case 103:this.$=b.addLocationDataFn(d[a],d[a])(new b.Access(new b.PropertyName("prototype")));
|
||||
break;case 106:this.$=b.addLocationDataFn(d[a-1],d[a])(b.extend(f[a],{soak:!0}));break;case 107:this.$=b.addLocationDataFn(d[a],d[a])(new b.Index(f[a]));break;case 108:this.$=b.addLocationDataFn(d[a],d[a])(new b.Slice(f[a]));break;case 109:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.Obj(f[a-2],f[a-3].generated));break;case 115:this.$=b.addLocationDataFn(d[a],d[a])(new b.Class);break;case 116:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Class(null,null,f[a]));break;case 117:this.$=b.addLocationDataFn(d[a-
|
||||
2],d[a])(new b.Class(null,f[a]));break;case 118:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.Class(null,f[a-1],f[a]));break;case 119:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Class(f[a]));break;case 120:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Class(f[a-1],null,f[a]));break;case 121:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.Class(f[a-2],f[a]));break;case 122:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Class(f[a-3],f[a-1],f[a]));break;case 123:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.ImportDeclaration(null,
|
||||
f[a]));break;case 124:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.ImportDeclaration(new b.ImportClause(f[a-2],null),f[a]));break;case 125:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.ImportDeclaration(new b.ImportClause(null,f[a-2]),f[a]));break;case 126:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.ImportDeclaration(new b.ImportClause(null,new b.ImportSpecifierList([])),f[a]));break;case 127:this.$=b.addLocationDataFn(d[a-6],d[a])(new b.ImportDeclaration(new b.ImportClause(null,new b.ImportSpecifierList(f[a-
|
||||
4])),f[a]));break;case 128:this.$=b.addLocationDataFn(d[a-5],d[a])(new b.ImportDeclaration(new b.ImportClause(f[a-4],f[a-2]),f[a]));break;case 129:this.$=b.addLocationDataFn(d[a-8],d[a])(new b.ImportDeclaration(new b.ImportClause(f[a-7],new b.ImportSpecifierList(f[a-4])),f[a]));break;case 133:case 153:case 169:case 185:this.$=b.addLocationDataFn(d[a-3],d[a])(f[a-2]);break;case 135:this.$=b.addLocationDataFn(d[a],d[a])(new b.ImportSpecifier(f[a]));break;case 136:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.ImportSpecifier(f[a-
|
||||
2],f[a]));break;case 137:this.$=b.addLocationDataFn(d[a],d[a])(new b.ImportSpecifier(new b.Literal(f[a])));break;case 138:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.ImportSpecifier(new b.Literal(f[a-2]),f[a]));break;case 139:this.$=b.addLocationDataFn(d[a],d[a])(new b.ImportDefaultSpecifier(f[a]));break;case 140:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.ImportNamespaceSpecifier(new b.Literal(f[a-2]),f[a]));break;case 141:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.ExportNamedDeclaration(new b.ExportSpecifierList([])));
|
||||
break;case 142:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.ExportNamedDeclaration(new b.ExportSpecifierList(f[a-2])));break;case 143:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.ExportNamedDeclaration(f[a]));break;case 144:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.ExportNamedDeclaration(new b.Assign(f[a-2],f[a],null,{moduleDeclaration:"export"})));break;case 145:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.ExportNamedDeclaration(new b.Assign(f[a-3],f[a],null,{moduleDeclaration:"export"})));
|
||||
break;case 146:this.$=b.addLocationDataFn(d[a-5],d[a])(new b.ExportNamedDeclaration(new b.Assign(f[a-4],f[a-1],null,{moduleDeclaration:"export"})));break;case 147:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.ExportDefaultDeclaration(f[a]));break;case 148:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.ExportAllDeclaration(new b.Literal(f[a-2]),f[a]));break;case 149:this.$=b.addLocationDataFn(d[a-6],d[a])(new b.ExportNamedDeclaration(new b.ExportSpecifierList(f[a-4]),f[a]));break;case 155:this.$=b.addLocationDataFn(d[a],
|
||||
d[a])(new b.ExportSpecifier(f[a]));break;case 156:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.ExportSpecifier(f[a-2],f[a]));break;case 157:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.ExportSpecifier(f[a-2],new b.Literal(f[a])));break;case 158:this.$=b.addLocationDataFn(d[a],d[a])(new b.ExportSpecifier(new b.Literal(f[a])));break;case 159:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.ExportSpecifier(new b.Literal(f[a-2]),f[a]));break;case 160:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.TaggedTemplateCall(f[a-
|
||||
2],f[a],f[a-1]));break;case 161:case 162:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Call(f[a-2],f[a],f[a-1]));break;case 164:this.$=b.addLocationDataFn(d[a],d[a])(new b.SuperCall);break;case 165:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.SuperCall(f[a]));break;case 166:this.$=b.addLocationDataFn(d[a],d[a])(!1);break;case 167:this.$=b.addLocationDataFn(d[a],d[a])(!0);break;case 168:this.$=b.addLocationDataFn(d[a-1],d[a])([]);break;case 170:case 171:this.$=b.addLocationDataFn(d[a],d[a])(new b.Value(new b.ThisLiteral));
|
||||
break;case 172:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Value(b.addLocationDataFn(d[a-1])(new b.ThisLiteral),[b.addLocationDataFn(d[a])(new b.Access(f[a]))],"this"));break;case 173:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Arr([]));break;case 174:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.Arr(f[a-2]));break;case 175:this.$=b.addLocationDataFn(d[a],d[a])("inclusive");break;case 176:this.$=b.addLocationDataFn(d[a],d[a])("exclusive");break;case 177:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Range(f[a-
|
||||
3],f[a-1],f[a-2]));break;case 178:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Range(f[a-2],f[a],f[a-1]));break;case 179:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Range(f[a-1],null,f[a]));break;case 180:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Range(null,f[a],f[a-1]));break;case 181:this.$=b.addLocationDataFn(d[a],d[a])(new b.Range(null,null,f[a]));break;case 191:this.$=b.addLocationDataFn(d[a-2],d[a])([].concat(f[a-2],f[a]));break;case 192:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Try(f[a]));
|
||||
break;case 193:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Try(f[a-1],f[a][0],f[a][1]));break;case 194:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.Try(f[a-2],null,null,f[a]));break;case 195:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Try(f[a-3],f[a-2][0],f[a-2][1],f[a]));break;case 196:this.$=b.addLocationDataFn(d[a-2],d[a])([f[a-1],f[a]]);break;case 197:this.$=b.addLocationDataFn(d[a-2],d[a])([b.addLocationDataFn(d[a-1])(new b.Value(f[a-1])),f[a]]);break;case 198:this.$=b.addLocationDataFn(d[a-
|
||||
1],d[a])([null,f[a]]);break;case 199:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Throw(f[a]));break;case 200:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Parens(f[a-1]));break;case 201:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Parens(f[a-2]));break;case 202:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.While(f[a]));break;case 203:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.While(f[a-2],{guard:f[a]}));break;case 204:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.While(f[a],{invert:!0}));break;
|
||||
case 205:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.While(f[a-2],{invert:!0,guard:f[a]}));break;case 206:this.$=b.addLocationDataFn(d[a-1],d[a])(f[a-1].addBody(f[a]));break;case 207:case 208:this.$=b.addLocationDataFn(d[a-1],d[a])(f[a].addBody(b.addLocationDataFn(d[a-1])(b.Block.wrap([f[a-1]]))));break;case 209:this.$=b.addLocationDataFn(d[a],d[a])(f[a]);break;case 210:this.$=b.addLocationDataFn(d[a-1],d[a])((new b.While(b.addLocationDataFn(d[a-1])(new b.BooleanLiteral("true")))).addBody(f[a]));
|
||||
break;case 211:this.$=b.addLocationDataFn(d[a-1],d[a])((new b.While(b.addLocationDataFn(d[a-1])(new b.BooleanLiteral("true")))).addBody(b.addLocationDataFn(d[a])(b.Block.wrap([f[a]]))));break;case 212:case 213:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.For(f[a-1],f[a]));break;case 214:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.For(f[a],f[a-1]));break;case 215:this.$=b.addLocationDataFn(d[a-1],d[a])({source:b.addLocationDataFn(d[a])(new b.Value(f[a]))});break;case 216:this.$=b.addLocationDataFn(d[a-
|
||||
3],d[a])({source:b.addLocationDataFn(d[a-2])(new b.Value(f[a-2])),step:f[a]});break;case 217:b=b.addLocationDataFn(d[a-1],d[a]);f[a].own=f[a-1].own;f[a].ownTag=f[a-1].ownTag;f[a].name=f[a-1][0];f[a].index=f[a-1][1];this.$=b(f[a]);break;case 218:this.$=b.addLocationDataFn(d[a-1],d[a])(f[a]);break;case 219:c=b.addLocationDataFn(d[a-2],d[a]);f[a].own=!0;f[a].ownTag=b.addLocationDataFn(d[a-1])(new b.Literal(f[a-1]));this.$=c(f[a]);break;case 225:this.$=b.addLocationDataFn(d[a-2],d[a])([f[a-2],f[a]]);
|
||||
break;case 226:this.$=b.addLocationDataFn(d[a-1],d[a])({source:f[a]});break;case 227:this.$=b.addLocationDataFn(d[a-1],d[a])({source:f[a],object:!0});break;case 228:this.$=b.addLocationDataFn(d[a-3],d[a])({source:f[a-2],guard:f[a]});break;case 229:this.$=b.addLocationDataFn(d[a-3],d[a])({source:f[a-2],guard:f[a],object:!0});break;case 230:this.$=b.addLocationDataFn(d[a-3],d[a])({source:f[a-2],step:f[a]});break;case 231:this.$=b.addLocationDataFn(d[a-5],d[a])({source:f[a-4],guard:f[a-2],step:f[a]});
|
||||
break;case 232:this.$=b.addLocationDataFn(d[a-5],d[a])({source:f[a-4],step:f[a-2],guard:f[a]});break;case 233:this.$=b.addLocationDataFn(d[a-1],d[a])({source:f[a],from:!0});break;case 234:this.$=b.addLocationDataFn(d[a-3],d[a])({source:f[a-2],guard:f[a],from:!0});break;case 235:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Switch(f[a-3],f[a-1]));break;case 236:this.$=b.addLocationDataFn(d[a-6],d[a])(new b.Switch(f[a-5],f[a-3],f[a-1]));break;case 237:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.Switch(null,
|
||||
f[a-1]));break;case 238:this.$=b.addLocationDataFn(d[a-5],d[a])(new b.Switch(null,f[a-3],f[a-1]));break;case 240:this.$=b.addLocationDataFn(d[a-1],d[a])(f[a-1].concat(f[a]));break;case 241:this.$=b.addLocationDataFn(d[a-2],d[a])([[f[a-1],f[a]]]);break;case 242:this.$=b.addLocationDataFn(d[a-3],d[a])([[f[a-2],f[a-1]]]);break;case 243:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.If(f[a-1],f[a],{type:f[a-2]}));break;case 244:this.$=b.addLocationDataFn(d[a-4],d[a])(f[a-4].addElse(b.addLocationDataFn(d[a-
|
||||
2],d[a])(new b.If(f[a-1],f[a],{type:f[a-2]}))));break;case 246:this.$=b.addLocationDataFn(d[a-2],d[a])(f[a-2].addElse(f[a]));break;case 247:case 248:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.If(f[a],b.addLocationDataFn(d[a-2])(b.Block.wrap([f[a-2]])),{type:f[a-1],statement:!0}));break;case 251:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Op("-",f[a]));break;case 252:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Op("+",f[a]));break;case 253:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Op("--",
|
||||
f[a]));break;case 254:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Op("++",f[a]));break;case 255:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Op("--",f[a-1],null,!0));break;case 256:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Op("++",f[a-1],null,!0));break;case 257:this.$=b.addLocationDataFn(d[a-1],d[a])(new b.Existence(f[a-1]));break;case 258:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Op("+",f[a-2],f[a]));break;case 259:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Op("-",f[a-2],f[a]));break;
|
||||
case 260:case 261:case 262:case 263:case 264:case 265:case 266:case 267:case 268:case 269:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Op(f[a-1],f[a-2],f[a]));break;case 270:d=b.addLocationDataFn(d[a-2],d[a]);f="!"===f[a-1].charAt(0)?(new b.Op(f[a-1].slice(1),f[a-2],f[a])).invert():new b.Op(f[a-1],f[a-2],f[a]);this.$=d(f);break;case 271:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Assign(f[a-2],f[a],f[a-1]));break;case 272:this.$=b.addLocationDataFn(d[a-4],d[a])(new b.Assign(f[a-4],f[a-1],f[a-3]));
|
||||
break;case 273:this.$=b.addLocationDataFn(d[a-3],d[a])(new b.Assign(f[a-3],f[a],f[a-2]));break;case 274:this.$=b.addLocationDataFn(d[a-2],d[a])(new b.Extends(f[a-2],f[a]))}},table:[{1:[2,1],3:1,4:2,5:3,7:4,8:5,9:6,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:t,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,
|
||||
97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{1:[3]},{1:[2,2],6:Ba},a(va,[2,3]),a(va,[2,6],{141:77,132:102,138:103,133:C,135:A,139:D,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(va,[2,7],{141:77,132:105,138:106,133:C,135:A,139:D,156:Ca}),a(va,[2,8]),a(ta,[2,14],{109:107,78:108,86:114,40:ua,41:ua,114:ua,82:Ra,83:Ga,
|
||||
84:Sa,85:Fa,87:Na,90:Oa,113:Ka}),a(ta,[2,15],{86:114,109:117,78:118,82:Ra,83:Ga,84:Sa,85:Fa,87:Na,90:Oa,113:Ka,114:ua}),a(ta,[2,16]),a(ta,[2,17]),a(ta,[2,18]),a(ta,[2,19]),a(ta,[2,20]),a(ta,[2,21]),a(ta,[2,22]),a(ta,[2,23]),a(ta,[2,24]),a(ta,[2,25]),a(ta,[2,26]),a(ya,[2,9]),a(ya,[2,10]),a(ya,[2,11]),a(ya,[2,12]),a(ya,[2,13]),a([1,6,32,42,131,133,135,139,156,163,164,165,166,167,168,169,170,171,172,173,174],na,{15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,10:20,11:21,13:23,
|
||||
14:24,54:26,47:27,79:28,80:29,81:30,111:31,66:33,77:40,154:41,132:43,136:44,138:45,74:53,75:54,37:55,43:57,33:70,60:71,141:77,39:80,7:120,8:122,12:c,28:ga,29:Ha,34:g,38:v,40:p,41:l,44:G,45:F,48:x,49:w,50:K,51:M,52:I,53:z,61:[1,119],62:N,63:k,67:m,68:q,92:r,95:h,97:y,105:O,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,137:W,149:P,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q}),a(Aa,Wa,{55:[1,124]}),a(Aa,[2,95]),a(Aa,[2,96]),a(Aa,[2,97]),a(Aa,[2,98]),a(b,[2,163]),a([6,31,65,70],n,{64:125,71:126,72:127,33:129,
|
||||
60:130,74:131,75:132,34:g,73:oa,92:r,118:f,119:d}),{30:135,31:wa},{7:137,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,
|
||||
158:U,159:aa,160:J,161:ca,162:Q},{7:138,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},
|
||||
{7:139,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:140,8:122,10:20,11:21,12:c,
|
||||
13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{15:142,16:143,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,
|
||||
44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:144,60:71,74:53,75:54,77:141,79:28,80:29,81:30,92:r,111:31,112:u,117:B,118:T,119:S,130:R},{15:142,16:143,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:144,60:71,74:53,75:54,77:145,79:28,80:29,81:30,92:r,111:31,112:u,117:B,118:T,119:S,130:R},a(La,xa,{96:[1,149],161:[1,146],162:[1,147],175:[1,148]}),a(ta,[2,245],{151:[1,150]}),{30:151,31:wa},{30:152,31:wa},a(ta,[2,209]),{30:153,31:wa},{7:154,8:122,10:20,
|
||||
11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:[1,155],33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Gb,[2,115],{47:27,79:28,80:29,81:30,
|
||||
111:31,74:53,75:54,37:55,43:57,33:70,60:71,39:80,15:142,16:143,54:144,30:156,77:158,31:wa,34:g,38:v,40:p,41:l,44:G,45:F,48:x,49:w,50:K,51:M,52:I,53:z,92:r,96:[1,157],112:u,117:B,118:T,119:S,130:R}),{7:159,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,
|
||||
105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(ya,$a,{15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,10:20,11:21,13:23,14:24,54:26,47:27,79:28,80:29,81:30,111:31,66:33,77:40,154:41,132:43,136:44,138:45,74:53,75:54,37:55,43:57,33:70,60:71,141:77,39:80,8:122,7:160,12:c,28:ga,34:g,38:v,40:p,41:l,44:G,45:F,48:x,49:w,50:K,51:M,52:I,53:z,61:E,62:N,63:k,67:m,
|
||||
68:q,92:r,95:h,97:y,105:O,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,137:W,149:P,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q}),a([1,6,31,32,42,70,94,131,133,135,139,156],[2,66]),{33:165,34:g,39:161,40:p,41:l,92:[1,164],98:162,99:163,104:Hb},{25:168,33:169,34:g,92:[1,167],95:h,103:[1,170],107:[1,171]},a(La,[2,92]),a(La,[2,93]),a(Aa,[2,40]),a(Aa,[2,41]),a(Aa,[2,42]),a(Aa,[2,43]),a(Aa,[2,44]),a(Aa,[2,45]),a(Aa,[2,46]),a(Aa,[2,47]),{4:172,5:3,7:4,8:5,9:6,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,
|
||||
19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:t,31:[1,173],33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:174,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,
|
||||
22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:ab,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,73:Va,74:53,75:54,76:179,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,116:176,117:B,118:T,119:S,120:Ib,123:177,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Aa,[2,170]),a(Aa,[2,171],{35:181,36:Ma}),a([1,6,31,32,42,46,65,70,
|
||||
73,82,83,84,85,87,89,90,94,113,115,120,122,131,133,134,135,139,140,156,159,160,163,164,165,166,167,168,169,170,171,172,173,174],[2,164],{110:183,114:ub}),{31:[2,69]},{31:[2,70]},a(Ia,[2,87]),a(Ia,[2,90]),{7:185,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,
|
||||
95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:186,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,
|
||||
117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:187,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,
|
||||
130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:189,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,30:188,31:wa,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,
|
||||
135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{33:194,34:g,60:195,74:196,75:197,80:190,92:r,118:f,119:S,143:191,144:[1,192],145:193},{142:198,146:[1,199],147:[1,200],148:[1,201]},a([6,31,70,94],Jb,{39:80,93:202,56:203,57:204,59:205,11:206,37:207,33:208,35:209,60:210,34:g,36:Ma,38:v,40:p,41:l,62:N,118:f}),a(Kb,[2,34]),a(Kb,[2,35]),a(Aa,[2,38]),{15:142,16:211,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,
|
||||
54:144,60:71,74:53,75:54,77:212,79:28,80:29,81:30,92:r,111:31,112:u,117:B,118:T,119:S,130:R},a([1,6,29,31,32,40,41,42,55,58,65,70,73,82,83,84,85,87,89,90,94,96,102,113,114,115,120,122,131,133,134,135,139,140,146,147,148,156,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175],[2,32]),a(Lb,[2,36]),{4:213,5:3,7:4,8:5,9:6,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:t,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,
|
||||
48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(va,[2,5],{7:4,8:5,9:6,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,10:20,11:21,13:23,14:24,54:26,47:27,79:28,80:29,81:30,111:31,66:33,77:40,154:41,132:43,136:44,138:45,74:53,75:54,
|
||||
37:55,43:57,33:70,60:71,141:77,39:80,5:214,12:c,28:t,34:g,38:v,40:p,41:l,44:G,45:F,48:x,49:w,50:K,51:M,52:I,53:z,61:E,62:N,63:k,67:m,68:q,92:r,95:h,97:y,105:O,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,133:C,135:A,137:W,139:D,149:P,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q}),a(ta,[2,257]),{7:215,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,
|
||||
54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:216,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,
|
||||
67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:217,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,
|
||||
79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:218,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,
|
||||
97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:219,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,
|
||||
118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:220,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,
|
||||
132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:221,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,
|
||||
138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:222,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,
|
||||
155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:223,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,
|
||||
161:ca,162:Q},{7:224,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:225,8:122,10:20,
|
||||
11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:226,8:122,10:20,11:21,12:c,13:23,14:24,15:7,
|
||||
16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:227,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,
|
||||
21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:228,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,
|
||||
26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(ta,[2,208]),a(ta,[2,213]),{7:229,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,
|
||||
26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(ta,[2,207]),a(ta,[2,212]),{39:230,40:p,41:l,110:231,114:ub},a(Ia,[2,88]),a(Mb,[2,167]),{35:232,36:Ma},{35:233,36:Ma},a(Ia,[2,103],{35:234,
|
||||
36:Ma}),{35:235,36:Ma},a(Ia,[2,104]),{7:237,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,73:Nb,74:53,75:54,77:40,79:28,80:29,81:30,88:236,91:238,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,121:239,122:vb,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,
|
||||
157:Z,158:U,159:aa,160:J,161:ca,162:Q},{86:242,87:Na,90:Oa},{110:243,114:ub},a(Ia,[2,89]),a(va,[2,65],{15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,10:20,11:21,13:23,14:24,54:26,47:27,79:28,80:29,81:30,111:31,66:33,77:40,154:41,132:43,136:44,138:45,74:53,75:54,37:55,43:57,33:70,60:71,141:77,39:80,8:122,7:244,12:c,28:ga,34:g,38:v,40:p,41:l,44:G,45:F,48:x,49:w,50:K,51:M,52:I,53:z,61:E,62:N,63:k,67:m,68:q,92:r,95:h,97:y,105:O,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,133:$a,
|
||||
135:$a,139:$a,156:$a,137:W,149:P,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q}),a(Ja,[2,28],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{7:245,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,
|
||||
92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{132:105,133:C,135:A,138:106,139:D,141:77,156:Ca},a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,163,164,165,166,167,168,169,170,171,172,173,174],na,{15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,10:20,11:21,13:23,14:24,54:26,47:27,79:28,80:29,81:30,111:31,66:33,77:40,
|
||||
154:41,132:43,136:44,138:45,74:53,75:54,37:55,43:57,33:70,60:71,141:77,39:80,7:120,8:122,12:c,28:ga,29:Ha,34:g,38:v,40:p,41:l,44:G,45:F,48:x,49:w,50:K,51:M,52:I,53:z,61:E,62:N,63:k,67:m,68:q,92:r,95:h,97:y,105:O,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,137:W,149:P,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q}),{6:[1,247],7:246,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:[1,248],33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,
|
||||
44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a([6,31],Ea,{69:251,65:[1,249],70:Ob}),a(Ta,[2,74]),a(Ta,[2,78],{55:[1,253],73:[1,252]}),a(Ta,[2,81]),a(hb,[2,82]),a(hb,[2,83]),a(hb,[2,84]),a(hb,[2,85]),{35:181,36:Ma},{7:254,8:122,10:20,11:21,12:c,
|
||||
13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:ab,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,73:Va,74:53,75:54,76:179,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,116:176,117:B,118:T,119:S,120:Ib,123:177,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(ta,[2,68]),{4:256,
|
||||
5:3,7:4,8:5,9:6,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:t,32:[1,255],33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a([1,6,31,32,42,
|
||||
65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,159,160,164,165,166,167,168,169,170,171,172,173,174],[2,249],{141:77,132:102,138:103,163:ea}),a(bb,[2,250],{141:77,132:102,138:103,163:ea,165:ia}),a(bb,[2,251],{141:77,132:102,138:103,163:ea,165:ia}),a(bb,[2,252],{141:77,132:102,138:103,163:ea,165:ia}),a(ta,[2,253],{40:xa,41:xa,82:xa,83:xa,84:xa,85:xa,87:xa,90:xa,113:xa,114:xa}),a(Mb,ua,{109:107,78:108,86:114,82:Ra,83:Ga,84:Sa,85:Fa,87:Na,90:Oa,113:Ka}),{78:118,82:Ra,83:Ga,84:Sa,85:Fa,86:114,
|
||||
87:Na,90:Oa,109:117,113:Ka,114:ua},a(Pb,Wa),a(ta,[2,254],{40:xa,41:xa,82:xa,83:xa,84:xa,85:xa,87:xa,90:xa,113:xa,114:xa}),a(ta,[2,255]),a(ta,[2,256]),{6:[1,259],7:257,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:[1,258],33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,
|
||||
118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:260,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,
|
||||
132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{30:261,31:wa,155:[1,262]},a(ta,[2,192],{126:263,127:[1,264],128:[1,265]}),a(ta,[2,206]),a(ta,[2,214]),{31:[1,266],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},{150:267,152:268,153:ib},a(ta,[2,116]),{7:270,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,
|
||||
24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Gb,[2,119],{30:271,31:wa,40:xa,41:xa,82:xa,83:xa,84:xa,85:xa,87:xa,90:xa,113:xa,114:xa,96:[1,272]}),a(Ja,[2,199],{141:77,
|
||||
132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(ya,cb,{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(ya,[2,123]),{29:[1,273],70:[1,274]},{29:[1,275]},{31:jb,33:280,34:g,94:[1,276],100:277,101:278,103:Xa},a([29,70],[2,139]),{102:[1,282]},{31:wb,33:287,34:g,94:[1,283],103:db,106:284,108:285},a(ya,[2,143]),{55:[1,289]},{7:290,8:122,10:20,11:21,12:c,13:23,14:24,
|
||||
15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{29:[1,291]},{6:Ba,131:[1,292]},{4:293,5:3,7:4,8:5,9:6,10:20,11:21,12:c,
|
||||
13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:t,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a([6,31,70,120],Qb,{141:77,132:102,138:103,121:294,73:[1,295],
|
||||
122:vb,133:C,135:A,139:D,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(xb,[2,173]),a([6,31,120],Ea,{69:296,70:kb}),a(Pa,[2,182]),{7:254,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:ab,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,73:Va,74:53,75:54,76:179,77:40,79:28,80:29,81:30,
|
||||
92:r,95:h,97:y,105:O,111:31,112:u,116:298,117:B,118:T,119:S,123:177,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Pa,[2,188]),a(Pa,[2,189]),a(Rb,[2,172]),a(Rb,[2,33]),a(b,[2,165]),{7:254,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:ab,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,
|
||||
62:N,63:k,66:33,67:m,68:q,73:Va,74:53,75:54,76:179,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,115:[1,299],116:300,117:B,118:T,119:S,123:177,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{30:301,31:wa,132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},a(Sb,[2,202],{141:77,132:102,138:103,133:C,134:[1,302],135:A,
|
||||
139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Sb,[2,204],{141:77,132:102,138:103,133:C,134:[1,303],135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(ta,[2,210]),a(Ya,[2,211],{141:77,132:102,138:103,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,156,
|
||||
159,160,163,164,165,166,167,168,169,170,171,172,173,174],[2,215],{140:[1,304]}),a(lb,[2,218]),{33:194,34:g,60:195,74:196,75:197,92:r,118:f,119:d,143:305,145:193},a(lb,[2,224],{70:[1,306]}),a(mb,[2,220]),a(mb,[2,221]),a(mb,[2,222]),a(mb,[2,223]),a(ta,[2,217]),{7:307,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,
|
||||
67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:308,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,
|
||||
79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:309,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,
|
||||
97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(nb,Ea,{69:310,70:Tb}),a(za,[2,111]),a(za,[2,51],{58:[1,312]}),a(Ub,[2,60],{55:[1,313]}),a(za,[2,56]),a(Ub,[2,61]),a(yb,[2,57]),a(yb,[2,58]),a(yb,[2,59]),{46:[1,314],78:118,82:Ra,83:Ga,84:Sa,85:Fa,86:114,87:Na,90:Oa,109:117,113:Ka,114:ua},a(Pb,xa),{6:Ba,42:[1,315]},a(va,[2,4]),a(Vb,[2,258],{141:77,132:102,138:103,163:ea,164:ha,
|
||||
165:ia}),a(Vb,[2,259],{141:77,132:102,138:103,163:ea,164:ha,165:ia}),a(bb,[2,260],{141:77,132:102,138:103,163:ea,165:ia}),a(bb,[2,261],{141:77,132:102,138:103,163:ea,165:ia}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,166,167,168,169,170,171,172,173,174],[2,262],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,167,168,169,170,171,172,173],[2,263],{141:77,132:102,138:103,159:ja,160:da,163:ea,
|
||||
164:ha,165:ia,166:ka,174:ma}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,168,169,170,171,172,173],[2,264],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,174:ma}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,169,170,171,172,173],[2,265],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,174:ma}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,170,171,172,173],[2,266],{141:77,
|
||||
132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,174:ma}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,171,172,173],[2,267],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,174:ma}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,172,173],[2,268],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,174:ma}),a([1,6,31,32,42,65,70,73,
|
||||
89,94,115,120,122,131,133,134,135,139,140,156,173],[2,269],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,174:ma}),a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,134,135,139,140,156,167,168,169,170,171,172,173,174],[2,270],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka}),a(Ya,[2,248],{141:77,132:102,138:103,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),
|
||||
a(Ya,[2,247],{141:77,132:102,138:103,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(b,[2,160]),a(b,[2,161]),a(Ia,[2,99]),a(Ia,[2,100]),a(Ia,[2,101]),a(Ia,[2,102]),{89:[1,316]},{73:Nb,89:[2,107],121:317,122:vb,132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},{89:[2,108]},{7:318,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,
|
||||
19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,89:[2,181],92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Wb,[2,175]),a(Wb,Xb),a(Ia,[2,106]),a(b,[2,162]),a(va,[2,64],{141:77,132:102,138:103,
|
||||
133:cb,135:cb,139:cb,156:cb,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Ja,[2,29],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Ja,[2,48],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{7:319,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,
|
||||
27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:320,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,
|
||||
38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{66:321,67:m,68:q},a(Qa,eb,{72:127,33:129,60:130,74:131,75:132,71:322,34:g,73:oa,92:r,118:f,119:d}),{6:Yb,31:Zb},a(Ta,[2,79]),{7:325,8:122,10:20,11:21,12:c,13:23,14:24,
|
||||
15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Pa,Qb,{141:77,132:102,138:103,73:[1,326],133:C,135:A,139:D,156:pa,159:ja,
|
||||
160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a($b,[2,30]),{6:Ba,32:[1,327]},a(Ja,[2,271],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{7:328,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,
|
||||
67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:329,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,
|
||||
79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Ja,[2,274],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(ta,[2,246]),{7:330,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,
|
||||
41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(ta,[2,193],{127:[1,331]}),{30:332,31:wa},{30:335,31:wa,33:333,34:g,75:334,92:r},{150:336,152:268,153:ib},{32:[1,337],151:[1,338],152:339,153:ib},a(ob,[2,239]),{7:341,8:122,10:20,11:21,
|
||||
12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,124:340,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(ac,[2,117],{141:77,132:102,138:103,30:342,31:wa,
|
||||
133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(ta,[2,120]),{7:343,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,
|
||||
135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{39:344,40:p,41:l},{92:[1,346],99:345,104:Hb},{39:347,40:p,41:l},{29:[1,348]},a(nb,Ea,{69:349,70:pb}),a(za,[2,130]),{31:jb,33:280,34:g,100:351,101:278,103:Xa},a(za,[2,135],{102:[1,352]}),a(za,[2,137],{102:[1,353]}),{33:354,34:g},a(ya,[2,141]),a(nb,Ea,{69:355,70:zb}),a(za,[2,150]),{31:wb,33:287,34:g,103:db,106:357,108:285},a(za,[2,155],{102:[1,358]}),a(za,[2,158],{102:[1,359]}),{6:[1,361],7:360,8:122,10:20,
|
||||
11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:[1,362],33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Ab,[2,147],{141:77,132:102,138:103,
|
||||
133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{39:363,40:p,41:l},a(Aa,[2,200]),{6:Ba,32:[1,364]},{7:365,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,
|
||||
119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a([12,28,34,38,40,41,44,45,48,49,50,51,52,53,61,62,63,67,68,92,95,97,105,112,117,118,119,125,129,130,133,135,137,139,149,155,157,158,159,160,161,162],Xb,{6:fb,31:fb,70:fb,120:fb}),{6:qb,31:rb,120:[1,366]},a([6,31,32,115,120],eb,{15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,10:20,11:21,13:23,14:24,54:26,47:27,79:28,80:29,81:30,111:31,66:33,
|
||||
77:40,154:41,132:43,136:44,138:45,74:53,75:54,37:55,43:57,33:70,60:71,141:77,39:80,8:122,76:179,7:254,123:369,12:c,28:ga,34:g,38:v,40:p,41:l,44:G,45:F,48:x,49:w,50:K,51:M,52:I,53:z,61:E,62:N,63:k,67:m,68:q,73:Va,92:r,95:h,97:y,105:O,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,133:C,135:A,137:W,139:D,149:P,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q}),a(Qa,Ea,{69:370,70:kb}),a(b,[2,168]),a([6,31,115],Ea,{69:371,70:kb}),a(bc,[2,243]),{7:372,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,
|
||||
20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:373,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,
|
||||
25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:374,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,
|
||||
34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(lb,[2,219]),{33:194,34:g,60:195,74:196,75:197,92:r,118:f,119:d,145:375},a([1,6,31,32,42,65,70,73,89,94,115,120,122,131,133,135,139,156],[2,226],{141:77,132:102,
|
||||
138:103,134:[1,376],140:[1,377],159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Bb,[2,227],{141:77,132:102,138:103,134:[1,378],159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Bb,[2,233],{141:77,132:102,138:103,134:[1,379],159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{6:cc,31:dc,94:[1,380]},a(Cb,eb,{39:80,57:204,59:205,11:206,37:207,33:208,35:209,
|
||||
60:210,56:383,34:g,36:Ma,38:v,40:p,41:l,62:N,118:f}),{7:384,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:[1,385],33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,
|
||||
158:U,159:aa,160:J,161:ca,162:Q},{7:386,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:[1,387],33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,
|
||||
161:ca,162:Q},a(Aa,[2,39]),a(Lb,[2,37]),a(Ia,[2,105]),{7:388,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,89:[2,179],92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,
|
||||
158:U,159:aa,160:J,161:ca,162:Q},{89:[2,180],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},a(Ja,[2,49],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{32:[1,389],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},{30:390,31:wa},a(Ta,
|
||||
[2,75]),{33:129,34:g,60:130,71:391,72:127,73:oa,74:131,75:132,92:r,118:f,119:d},a(ec,n,{71:126,72:127,33:129,60:130,74:131,75:132,64:392,34:g,73:oa,92:r,118:f,119:d}),a(Ta,[2,80],{141:77,132:102,138:103,133:C,135:A,139:D,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Pa,fb),a($b,[2,31]),{32:[1,393],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},
|
||||
a(Ja,[2,273],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{30:394,31:wa,132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},{30:395,31:wa},a(ta,[2,194]),{30:396,31:wa},{30:397,31:wa},a(Db,[2,198]),{32:[1,398],151:[1,399],152:339,153:ib},a(ta,[2,237]),{30:400,31:wa},a(ob,[2,240]),{30:401,31:wa,70:[1,402]},a(fc,[2,190],{141:77,132:102,
|
||||
138:103,133:C,135:A,139:D,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(ta,[2,118]),a(ac,[2,121],{141:77,132:102,138:103,30:403,31:wa,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(ya,[2,124]),{29:[1,404]},{31:jb,33:280,34:g,100:405,101:278,103:Xa},a(ya,[2,125]),{39:406,40:p,41:l},{6:sb,31:tb,94:[1,407]},a(Cb,eb,{33:280,101:410,34:g,103:Xa}),a(Qa,Ea,{69:411,70:pb}),{33:412,
|
||||
34:g},{33:413,34:g},{29:[2,140]},{6:Eb,31:Fb,94:[1,414]},a(Cb,eb,{33:287,108:417,34:g,103:db}),a(Qa,Ea,{69:418,70:zb}),{33:419,34:g,103:[1,420]},{33:421,34:g},a(Ab,[2,144],{141:77,132:102,138:103,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{7:422,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,
|
||||
50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:423,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,
|
||||
61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(ya,[2,148]),{131:[1,424]},{120:[1,425],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},a(xb,[2,174]),{7:254,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,
|
||||
18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,73:Va,74:53,75:54,76:179,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,123:426,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:254,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,
|
||||
20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,31:ab,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,73:Va,74:53,75:54,76:179,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,116:427,117:B,118:T,119:S,123:177,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(Pa,[2,183]),{6:qb,31:rb,32:[1,428]},{6:qb,31:rb,115:[1,429]},
|
||||
a(Ya,[2,203],{141:77,132:102,138:103,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Ya,[2,205],{141:77,132:102,138:103,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Ya,[2,216],{141:77,132:102,138:103,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(lb,[2,225]),{7:430,8:122,10:20,11:21,12:c,
|
||||
13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:431,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,
|
||||
19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:432,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,
|
||||
24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:433,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,
|
||||
33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(xb,[2,109]),{11:206,33:208,34:g,35:209,36:Ma,37:207,38:v,39:80,40:p,41:l,56:434,57:204,59:205,60:210,62:N,118:f},a(ec,Jb,{39:80,56:203,57:204,59:205,
|
||||
11:206,37:207,33:208,35:209,60:210,93:435,34:g,36:Ma,38:v,40:p,41:l,62:N,118:f}),a(za,[2,112]),a(za,[2,52],{141:77,132:102,138:103,133:C,135:A,139:D,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{7:436,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,
|
||||
68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(za,[2,54],{141:77,132:102,138:103,133:C,135:A,139:D,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{7:437,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,
|
||||
33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{89:[2,178],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},
|
||||
a(ta,[2,50]),a(ta,[2,67]),a(Ta,[2,76]),a(Qa,Ea,{69:438,70:Ob}),a(ta,[2,272]),a(bc,[2,244]),a(ta,[2,195]),a(Db,[2,196]),a(Db,[2,197]),a(ta,[2,235]),{30:439,31:wa},{32:[1,440]},a(ob,[2,241],{6:[1,441]}),{7:442,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,
|
||||
97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},a(ta,[2,122]),{39:443,40:p,41:l},a(nb,Ea,{69:444,70:pb}),a(ya,[2,126]),{29:[1,445]},{33:280,34:g,101:446,103:Xa},{31:jb,33:280,34:g,100:447,101:278,103:Xa},a(za,[2,131]),{6:sb,31:tb,32:[1,448]},a(za,[2,136]),a(za,[2,138]),a(ya,[2,142],{29:[1,449]}),{33:287,34:g,103:db,108:450},{31:wb,33:287,34:g,103:db,106:451,108:285},a(za,[2,151]),
|
||||
{6:Eb,31:Fb,32:[1,452]},a(za,[2,156]),a(za,[2,157]),a(za,[2,159]),a(Ab,[2,145],{141:77,132:102,138:103,133:C,135:A,139:D,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),{32:[1,453],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},a(Aa,[2,201]),a(Aa,[2,177]),a(Pa,[2,184]),a(Qa,Ea,{69:454,70:kb}),a(Pa,[2,185]),a(b,[2,169]),a([1,6,31,32,42,65,70,73,89,94,115,
|
||||
120,122,131,133,134,135,139,156],[2,228],{141:77,132:102,138:103,140:[1,455],159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Bb,[2,230],{141:77,132:102,138:103,134:[1,456],159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Ja,[2,229],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Ja,[2,234],{141:77,132:102,138:103,159:ja,
|
||||
160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(za,[2,113]),a(Qa,Ea,{69:457,70:Tb}),{32:[1,458],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},{32:[1,459],132:102,133:C,135:A,138:103,139:D,141:77,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma},{6:Yb,31:Zb,32:[1,460]},{32:[1,461]},a(ta,[2,238]),a(ob,[2,
|
||||
242]),a(fc,[2,191],{141:77,132:102,138:103,133:C,135:A,139:D,156:pa,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(ya,[2,128]),{6:sb,31:tb,94:[1,462]},{39:463,40:p,41:l},a(za,[2,132]),a(Qa,Ea,{69:464,70:pb}),a(za,[2,133]),{39:465,40:p,41:l},a(za,[2,152]),a(Qa,Ea,{69:466,70:zb}),a(za,[2,153]),a(ya,[2,146]),{6:qb,31:rb,32:[1,467]},{7:468,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,
|
||||
28:ga,33:70,34:g,37:55,38:v,39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{7:469,8:122,10:20,11:21,12:c,13:23,14:24,15:7,16:8,17:9,18:10,19:11,20:12,21:13,22:14,23:15,24:16,25:17,26:18,27:19,28:ga,33:70,34:g,37:55,38:v,
|
||||
39:80,40:p,41:l,43:57,44:G,45:F,47:27,48:x,49:w,50:K,51:M,52:I,53:z,54:26,60:71,61:E,62:N,63:k,66:33,67:m,68:q,74:53,75:54,77:40,79:28,80:29,81:30,92:r,95:h,97:y,105:O,111:31,112:u,117:B,118:T,119:S,125:H,129:ba,130:R,132:43,133:C,135:A,136:44,137:W,138:45,139:D,141:77,149:P,154:41,155:Y,157:Z,158:U,159:aa,160:J,161:ca,162:Q},{6:cc,31:dc,32:[1,470]},a(za,[2,53]),a(za,[2,55]),a(Ta,[2,77]),a(ta,[2,236]),{29:[1,471]},a(ya,[2,127]),{6:sb,31:tb,32:[1,472]},a(ya,[2,149]),{6:Eb,31:Fb,32:[1,473]},a(Pa,[2,
|
||||
186]),a(Ja,[2,231],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(Ja,[2,232],{141:77,132:102,138:103,159:ja,160:da,163:ea,164:ha,165:ia,166:ka,167:la,168:L,169:fa,170:qa,171:ra,172:X,173:sa,174:ma}),a(za,[2,114]),{39:474,40:p,41:l},a(za,[2,134]),a(za,[2,154]),a(ya,[2,129])],defaultActions:{68:[2,69],69:[2,70],238:[2,108],354:[2,140]},parseError:function(a,b){if(b.recoverable)this.trace(a);else{var d=function(a,b){this.message=
|
||||
a;this.hash=b};d.prototype=Error;throw new d(a,b);}},parse:function(a){var b=[0],d=[null],f=[],n=this.table,oa="",c=0,g=0,e=0,h=f.slice.call(arguments,1),wa=Object.create(this.lexer),La={},k;for(k in this.yy)Object.prototype.hasOwnProperty.call(this.yy,k)&&(La[k]=this.yy[k]);wa.setInput(a,La);La.lexer=wa;La.parser=this;"undefined"==typeof wa.yylloc&&(wa.yylloc={});k=wa.yylloc;f.push(k);var m=wa.options&&wa.options.ranges;this.parseError="function"===typeof La.parseError?La.parseError:Object.getPrototypeOf(this).parseError;
|
||||
for(var q,Wa,p,r,y={},l,u;;){p=b[b.length-1];if(this.defaultActions[p])r=this.defaultActions[p];else{if(null===q||"undefined"==typeof q)q=wa.lex()||1,"number"!==typeof q&&(q=this.symbols_[q]||q);r=n[p]&&n[p][q]}if("undefined"===typeof r||!r.length||!r[0]){var xa;u=[];for(l in n[p])this.terminals_[l]&&2<l&&u.push("'"+this.terminals_[l]+"'");xa=wa.showPosition?"Parse error on line "+(c+1)+":\n"+wa.showPosition()+"\nExpecting "+u.join(", ")+", got '"+(this.terminals_[q]||q)+"'":"Parse error on line "+
|
||||
(c+1)+": Unexpected "+(1==q?"end of input":"'"+(this.terminals_[q]||q)+"'");this.parseError(xa,{text:wa.match,token:this.terminals_[q]||q,line:wa.yylineno,loc:k,expected:u})}if(r[0]instanceof Array&&1<r.length)throw Error("Parse Error: multiple actions possible at state: "+p+", token: "+q);switch(r[0]){case 1:b.push(q);d.push(wa.yytext);f.push(wa.yylloc);b.push(r[1]);q=null;Wa?(q=Wa,Wa=null):(g=wa.yyleng,oa=wa.yytext,c=wa.yylineno,k=wa.yylloc,0<e&&e--);break;case 2:u=this.productions_[r[1]][1];y.$=
|
||||
d[d.length-u];y._$={first_line:f[f.length-(u||1)].first_line,last_line:f[f.length-1].last_line,first_column:f[f.length-(u||1)].first_column,last_column:f[f.length-1].last_column};m&&(y._$.range=[f[f.length-(u||1)].range[0],f[f.length-1].range[1]]);p=this.performAction.apply(y,[oa,g,c,La,r[1],d,f].concat(h));if("undefined"!==typeof p)return p;u&&(b=b.slice(0,-2*u),d=d.slice(0,-1*u),f=f.slice(0,-1*u));b.push(this.productions_[r[1]][0]);d.push(y.$);f.push(y._$);r=n[b[b.length-2]][b[b.length-1]];b.push(r);
|
||||
break;case 3:return!0}}}};e.prototype=gc;gc.Parser=e;return new e}();"undefined"!==typeof t&&"undefined"!==typeof e&&(e.parser=Ba,e.Parser=Ba.Parser,e.parse=function(){return Ba.parse.apply(Ba,arguments)},e.main=function(V){V[1]||(console.log("Usage: "+V[0]+" FILE"),process.exit(1));var a="",c=t("fs");"undefined"!==typeof c&&null!==c&&(a=c.readFileSync(t("path").normalize(V[1]),"utf8"));return e.parser.parse(a)},"undefined"!==typeof va&&t.main===va&&e.main(process.argv.slice(1)));return va.exports}();
|
||||
t["./scope"]=function(){var e={};(function(){var t=[].indexOf||function(e){for(var V=0,a=this.length;V<a;V++)if(V in this&&this[V]===e)return V;return-1};e.Scope=function(){function e(e,a,c,t){var g,V;this.parent=e;this.expressions=a;this.method=c;this.referencedVars=t;this.variables=[{name:"arguments",type:"arguments"}];this.positions={};this.parent||(this.utilities={});this.root=null!=(g=null!=(V=this.parent)?V.root:void 0)?g:this}e.prototype.add=function(e,a,c){return this.shared&&!c?this.parent.add(e,
|
||||
a,c):Object.prototype.hasOwnProperty.call(this.positions,e)?this.variables[this.positions[e]].type=a:this.positions[e]=this.variables.push({name:e,type:a})-1};e.prototype.namedMethod=function(){var e;return null!=(e=this.method)&&e.name||!this.parent?this.method:this.parent.namedMethod()};e.prototype.find=function(e,a){null==a&&(a="var");if(this.check(e))return!0;this.add(e,a);return!1};e.prototype.parameter=function(e){if(!this.shared||!this.parent.check(e,!0))return this.add(e,"param")};e.prototype.check=
|
||||
function(e){var a;return!!(this.type(e)||null!=(a=this.parent)&&a.check(e))};e.prototype.temporary=function(e,a,c){null==c&&(c=!1);return c?(c=e.charCodeAt(0),e=122-c,c=String.fromCharCode(c+a%(e+1)),a=Math.floor(a/(e+1)),""+c+(a||"")):""+e+(a||"")};e.prototype.type=function(e){var a,c,t,g;t=this.variables;a=0;for(c=t.length;a<c;a++)if(g=t[a],g.name===e)return g.type;return null};e.prototype.freeVariable=function(e,a){var c,V,g;null==a&&(a={});for(c=0;;){g=this.temporary(e,c,a.single);if(!(this.check(g)||
|
||||
0<=t.call(this.root.referencedVars,g)))break;c++}(null!=(V=a.reserve)?V:1)&&this.add(g,"var",!0);return g};e.prototype.assign=function(e,a){this.add(e,{value:a,assigned:!0},!0);return this.hasAssignments=!0};e.prototype.hasDeclarations=function(){return!!this.declaredVariables().length};e.prototype.declaredVariables=function(){var e,a,c,t,g;t=this.variables;g=[];a=0;for(c=t.length;a<c;a++)e=t[a],"var"===e.type&&g.push(e.name);return g.sort()};e.prototype.assignedVariables=function(){var e,a,c,t,g;
|
||||
c=this.variables;t=[];e=0;for(a=c.length;e<a;e++)g=c[e],g.type.assigned&&t.push(g.name+" \x3d "+g.type.value);return t};return e}()}).call(this);return e}();t["./nodes"]=function(){var e={};(function(){var va,pa,V,a,c,Da,g,v,p,l,G,F,x,w,K,M,I,z,E,N,k,m,q,r,h,y,O,u,B,T,S,H,ba,R,C,A,W,D,P,Y,Z,U,aa,J,ca,Q,ua,Za,Ua,ja,da,ea,ha,ia,ka,la,L,fa,qa,ra,X,sa,ma,Ca,ta,gb,Ra,Ga,Sa,Fa,Na,Oa,Ka,ya,na=function(a,b){function n(){this.constructor=a}for(var oa in b)ga.call(b,oa)&&(a[oa]=b[oa]);n.prototype=b.prototype;
|
||||
a.prototype=new n;a.__super__=b.prototype;return a},ga={}.hasOwnProperty,Ha=[].indexOf||function(a){for(var b=0,n=this.length;b<n;b++)if(b in this&&this[b]===a)return b;return-1},Aa=[].slice;Error.stackTraceLimit=Infinity;J=t("./scope").Scope;a=t("./lexer");Ga=a.isUnassignable;m=a.JS_FORBIDDEN;w=t("./helpers");ra=w.compact;ma=w.flatten;sa=w.extend;Fa=w.merge;X=w.del;a=w.addLocationDataFn;Sa=w.locationDataToString;Oa=w.throwSyntaxError;e.extend=sa;e.addLocationDataFn=a;fa=function(){return!0};H=function(){return!1};
|
||||
ea=function(){return this};S=function(){this.negated=!this.negated;return this};e.CodeFragment=l=function(){function a(a,n){var b;this.code=""+n;this.locationData=null!=a?a.locationData:void 0;this.type=(null!=a?null!=(b=a.constructor)?b.name:void 0:void 0)||"unknown"}a.prototype.toString=function(){return""+this.code+(this.locationData?": "+Sa(this.locationData):"")};return a}();Ca=function(a){var b,n,oa,f;f=[];n=0;for(oa=a.length;n<oa;n++)b=a[n],f.push(b.code);return f.join("")};e.Base=a=function(){function a(){}
|
||||
a.prototype.compile=function(a,n){return Ca(this.compileToFragments(a,n))};a.prototype.compileToFragments=function(a,n){a=sa({},a);n&&(a.level=n);n=this.unfoldSoak(a)||this;n.tab=a.indent;return a.level!==u&&n.isStatement(a)?n.compileClosure(a):n.compileNode(a)};a.prototype.compileClosure=function(a){var b,oa,f,d;(f=this.jumps())&&f.error("cannot use a pure statement in an expression");a.sharedScope=!0;f=new p([],c.wrap([this]));b=[];if((oa=this.contains(gb))||this.contains(Ra))b=[new ha],oa?(oa=
|
||||
"apply",b.push(new z("arguments"))):oa="call",f=new L(f,[new va(new P(oa))]);a=(new g(f,b)).compileNode(a);if(f.isGenerator||null!=(d=f.base)&&d.isGenerator)a.unshift(this.makeCode("(yield* ")),a.push(this.makeCode(")"));return a};a.prototype.cache=function(a,n,oa){var b;if(null!=oa?oa(this):this.isComplex())return oa=new z(a.scope.freeVariable("ref")),b=new V(oa,this),n?[b.compileToFragments(a,n),[this.makeCode(oa.value)]]:[b,oa];oa=n?this.compileToFragments(a,n):this;return[oa,oa]};a.prototype.cacheToCodeFragments=
|
||||
function(a){return[Ca(a[0]),Ca(a[1])]};a.prototype.makeReturn=function(a){var b;b=this.unwrapAll();return a?new g(new B(a+".push"),[b]):new U(b)};a.prototype.contains=function(a){var b;b=void 0;this.traverseChildren(!1,function(n){if(a(n))return b=n,!1});return b};a.prototype.lastNonComment=function(a){var b;for(b=a.length;b--;)if(!(a[b]instanceof G))return a[b];return null};a.prototype.toString=function(a,n){var b;null==a&&(a="");null==n&&(n=this.constructor.name);b="\n"+a+n;this.soak&&(b+="?");
|
||||
this.eachChild(function(f){return b+=f.toString(a+da)});return b};a.prototype.eachChild=function(a){var b,oa,f,d,c,e,g;if(!this.children)return this;e=this.children;oa=0;for(d=e.length;oa<d;oa++)if(b=e[oa],this[b])for(g=ma([this[b]]),f=0,c=g.length;f<c;f++)if(b=g[f],!1===a(b))return this;return this};a.prototype.traverseChildren=function(a,n){return this.eachChild(function(b){if(!1!==n(b))return b.traverseChildren(a,n)})};a.prototype.invert=function(){return new A("!",this)};a.prototype.unwrapAll=
|
||||
function(){var a;for(a=this;a!==(a=a.unwrap()););return a};a.prototype.children=[];a.prototype.isStatement=H;a.prototype.jumps=H;a.prototype.isComplex=fa;a.prototype.isChainable=H;a.prototype.isAssignable=H;a.prototype.isNumber=H;a.prototype.unwrap=ea;a.prototype.unfoldSoak=H;a.prototype.assigns=H;a.prototype.updateLocationDataIfMissing=function(a){if(this.locationData)return this;this.locationData=a;return this.eachChild(function(b){return b.updateLocationDataIfMissing(a)})};a.prototype.error=function(a){return Oa(a,
|
||||
this.locationData)};a.prototype.makeCode=function(a){return new l(this,a)};a.prototype.wrapInBraces=function(a){return[].concat(this.makeCode("("),a,this.makeCode(")"))};a.prototype.joinFragmentArrays=function(a,n){var b,f,d,c,e;b=[];d=c=0;for(e=a.length;c<e;d=++c)f=a[d],d&&b.push(this.makeCode(n)),b=b.concat(f);return b};return a}();e.Block=c=function(a){function b(a){this.expressions=ra(ma(a||[]))}na(b,a);b.prototype.children=["expressions"];b.prototype.push=function(a){this.expressions.push(a);
|
||||
return this};b.prototype.pop=function(){return this.expressions.pop()};b.prototype.unshift=function(a){this.expressions.unshift(a);return this};b.prototype.unwrap=function(){return 1===this.expressions.length?this.expressions[0]:this};b.prototype.isEmpty=function(){return!this.expressions.length};b.prototype.isStatement=function(a){var b,f,d,n;n=this.expressions;f=0;for(d=n.length;f<d;f++)if(b=n[f],b.isStatement(a))return!0;return!1};b.prototype.jumps=function(a){var b,f,d,n;n=this.expressions;f=
|
||||
0;for(d=n.length;f<d;f++)if(b=n[f],b=b.jumps(a))return b};b.prototype.makeReturn=function(a){var b,f;for(f=this.expressions.length;f--;)if(b=this.expressions[f],!(b instanceof G)){this.expressions[f]=b.makeReturn(a);b instanceof U&&!b.expression&&this.expressions.splice(f,1);break}return this};b.prototype.compileToFragments=function(a,oa){null==a&&(a={});return a.scope?b.__super__.compileToFragments.call(this,a,oa):this.compileRoot(a)};b.prototype.compileNode=function(a){var n,f,d,c,e,g,k;this.tab=
|
||||
a.indent;k=a.level===u;f=[];g=this.expressions;d=n=0;for(c=g.length;n<c;d=++n)e=g[d],e=e.unwrapAll(),e=e.unfoldSoak(a)||e,e instanceof b?f.push(e.compileNode(a)):k?(e.front=!0,d=e.compileToFragments(a),e.isStatement(a)||(d.unshift(this.makeCode(""+this.tab)),d.push(this.makeCode(";"))),f.push(d)):f.push(e.compileToFragments(a,h));if(k)return this.spaced?[].concat(this.joinFragmentArrays(f,"\n\n"),this.makeCode("\n")):this.joinFragmentArrays(f,"\n");n=f.length?this.joinFragmentArrays(f,", "):[this.makeCode("void 0")];
|
||||
return 1<f.length&&a.level>=h?this.wrapInBraces(n):n};b.prototype.compileRoot=function(a){var b,f,d,n,c;a.indent=a.bare?"":da;a.level=u;this.spaced=!0;a.scope=new J(null,this,null,null!=(d=a.referencedVars)?d:[]);c=a.locals||[];d=0;for(f=c.length;d<f;d++)n=c[d],a.scope.parameter(n);d=[];if(!a.bare){var e;e=this.expressions;f=[];b=n=0;for(c=e.length;n<c;b=++n){b=e[b];if(!(b.unwrap()instanceof G))break;f.push(b)}n=this.expressions.slice(f.length);this.expressions=f;f.length&&(d=this.compileNode(Fa(a,
|
||||
{indent:""})),d.push(this.makeCode("\n")));this.expressions=n}f=this.compileWithDeclarations(a);return a.bare?f:[].concat(d,this.makeCode("(function() {\n"),f,this.makeCode("\n}).call(this);\n"))};b.prototype.compileWithDeclarations=function(a){var b,f,d,n,c,e;d=[];e=this.expressions;n=c=0;for(b=e.length;c<b&&(f=e[n],f=f.unwrap(),f instanceof G||f instanceof B);n=++c);a=Fa(a,{level:u});n&&(f=this.expressions.splice(n,9E9),d=[this.spaced,!1],c=d[0],this.spaced=d[1],c=[this.compileNode(a),c],d=c[0],
|
||||
this.spaced=c[1],this.expressions=f);f=this.compileNode(a);c=a.scope;c.expressions===this&&(b=a.scope.hasDeclarations(),a=c.hasAssignments,b||a?(n&&d.push(this.makeCode("\n")),d.push(this.makeCode(this.tab+"var ")),b&&d.push(this.makeCode(c.declaredVariables().join(", "))),a&&(b&&d.push(this.makeCode(",\n"+(this.tab+da))),d.push(this.makeCode(c.assignedVariables().join(",\n"+(this.tab+da))))),d.push(this.makeCode(";\n"+(this.spaced?"\n":"")))):d.length&&f.length&&d.push(this.makeCode("\n")));return d.concat(f)};
|
||||
b.wrap=function(a){return 1===a.length&&a[0]instanceof b?a[0]:new b(a)};return b}(a);e.Literal=B=function(a){function b(a){this.value=a}na(b,a);b.prototype.isComplex=H;b.prototype.assigns=function(a){return a===this.value};b.prototype.compileNode=function(a){return[this.makeCode(this.value)]};b.prototype.toString=function(){return" "+(this.isStatement()?b.__super__.toString.apply(this,arguments):this.constructor.name)+": "+this.value};return b}(a);e.NumberLiteral=R=function(a){function b(){return b.__super__.constructor.apply(this,
|
||||
arguments)}na(b,a);return b}(B);e.InfinityLiteral=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);b.prototype.compileNode=function(){return[this.makeCode("2e308")]};return b}(R);e.NaNLiteral=function(a){function b(){b.__super__.constructor.call(this,"NaN")}na(b,a);b.prototype.compileNode=function(a){var b;b=[this.makeCode("0/0")];return a.level>=y?this.wrapInBraces(b):b};return b}(R);e.StringLiteral=Za=function(a){function b(){return b.__super__.constructor.apply(this,
|
||||
arguments)}na(b,a);return b}(B);e.RegexLiteral=Z=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);return b}(B);e.PassthroughLiteral=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);return b}(B);e.IdentifierLiteral=z=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);b.prototype.isAssignable=fa;return b}(B);e.PropertyName=P=function(a){function b(){return b.__super__.constructor.apply(this,
|
||||
arguments)}na(b,a);b.prototype.isAssignable=fa;return b}(B);e.StatementLiteral=ua=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);b.prototype.isStatement=fa;b.prototype.makeReturn=ea;b.prototype.jumps=function(a){if("break"===this.value&&!(null!=a&&a.loop||null!=a&&a.block)||"continue"===this.value&&(null==a||!a.loop))return this};b.prototype.compileNode=function(a){return[this.makeCode(""+this.tab+this.value+";")]};return b}(B);e.ThisLiteral=ha=function(a){function b(){b.__super__.constructor.call(this,
|
||||
"this")}na(b,a);b.prototype.compileNode=function(a){var b;a=null!=(b=a.scope.method)&&b.bound?a.scope.method.context:this.value;return[this.makeCode(a)]};return b}(B);e.UndefinedLiteral=la=function(a){function b(){b.__super__.constructor.call(this,"undefined")}na(b,a);b.prototype.compileNode=function(a){return[this.makeCode(a.level>=q?"(void 0)":"void 0")]};return b}(B);e.NullLiteral=ba=function(a){function b(){b.__super__.constructor.call(this,"null")}na(b,a);return b}(B);e.BooleanLiteral=Da=function(a){function b(){return b.__super__.constructor.apply(this,
|
||||
arguments)}na(b,a);return b}(B);e.Return=U=function(a){function b(a){this.expression=a}na(b,a);b.prototype.children=["expression"];b.prototype.isStatement=fa;b.prototype.makeReturn=ea;b.prototype.jumps=ea;b.prototype.compileToFragments=function(a,oa){var f,d;f=null!=(d=this.expression)?d.makeReturn():void 0;return!f||f instanceof b?b.__super__.compileToFragments.call(this,a,oa):f.compileToFragments(a,oa)};b.prototype.compileNode=function(a){var b;b=[];b.push(this.makeCode(this.tab+("return"+(this.expression?
|
||||
" ":""))));this.expression&&(b=b.concat(this.expression.compileToFragments(a,O)));b.push(this.makeCode(";"));return b};return b}(a);e.YieldReturn=qa=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);b.prototype.compileNode=function(a){null==a.scope.parent&&this.error("yield can only occur inside functions");return b.__super__.compileNode.apply(this,arguments)};return b}(U);e.Value=L=function(a){function b(a,oa,f){if(!oa&&a instanceof b)return a;this.base=a;this.properties=
|
||||
oa||[];f&&(this[f]=!0);return this}na(b,a);b.prototype.children=["base","properties"];b.prototype.add=function(a){this.properties=this.properties.concat(a);return this};b.prototype.hasProperties=function(){return!!this.properties.length};b.prototype.bareLiteral=function(a){return!this.properties.length&&this.base instanceof a};b.prototype.isArray=function(){return this.bareLiteral(pa)};b.prototype.isRange=function(){return this.bareLiteral(Y)};b.prototype.isComplex=function(){return this.hasProperties()||
|
||||
this.base.isComplex()};b.prototype.isAssignable=function(){return this.hasProperties()||this.base.isAssignable()};b.prototype.isNumber=function(){return this.bareLiteral(R)};b.prototype.isString=function(){return this.bareLiteral(Za)};b.prototype.isRegex=function(){return this.bareLiteral(Z)};b.prototype.isUndefined=function(){return this.bareLiteral(la)};b.prototype.isNull=function(){return this.bareLiteral(ba)};b.prototype.isBoolean=function(){return this.bareLiteral(Da)};b.prototype.isAtomic=function(){var a,
|
||||
b,f,d;d=this.properties.concat(this.base);a=0;for(b=d.length;a<b;a++)if(f=d[a],f.soak||f instanceof g)return!1;return!0};b.prototype.isNotCallable=function(){return this.isNumber()||this.isString()||this.isRegex()||this.isArray()||this.isRange()||this.isSplice()||this.isObject()||this.isUndefined()||this.isNull()||this.isBoolean()};b.prototype.isStatement=function(a){return!this.properties.length&&this.base.isStatement(a)};b.prototype.assigns=function(a){return!this.properties.length&&this.base.assigns(a)};
|
||||
b.prototype.jumps=function(a){return!this.properties.length&&this.base.jumps(a)};b.prototype.isObject=function(a){return this.properties.length?!1:this.base instanceof C&&(!a||this.base.generated)};b.prototype.isSplice=function(){var a;a=this.properties;return a[a.length-1]instanceof ca};b.prototype.looksStatic=function(a){var b;return this.base.value===a&&1===this.properties.length&&"prototype"!==(null!=(b=this.properties[0].name)?b.value:void 0)};b.prototype.unwrap=function(){return this.properties.length?
|
||||
this:this.base};b.prototype.cacheReference=function(a){var n,f,d,c;n=this.properties;d=n[n.length-1];if(2>this.properties.length&&!this.base.isComplex()&&(null==d||!d.isComplex()))return[this,this];n=new b(this.base,this.properties.slice(0,-1));n.isComplex()&&(f=new z(a.scope.freeVariable("base")),n=new b(new D(new V(f,n))));if(!d)return[n,f];d.isComplex()&&(c=new z(a.scope.freeVariable("name")),d=new k(new V(c,d.index)),c=new k(c));return[n.add(d),new b(f||n.base,[c||d])]};b.prototype.compileNode=
|
||||
function(a){var b,f,d,n,c;this.base.front=this.front;c=this.properties;b=this.base.compileToFragments(a,c.length?q:null);c.length&&aa.test(Ca(b))&&b.push(this.makeCode("."));f=0;for(d=c.length;f<d;f++)n=c[f],b.push.apply(b,n.compileToFragments(a));return b};b.prototype.unfoldSoak=function(a){return null!=this.unfoldedSoak?this.unfoldedSoak:this.unfoldedSoak=function(n){return function(){var f,d,c,oa,e;if(d=n.base.unfoldSoak(a))return(f=d.body.properties).push.apply(f,n.properties),d;e=n.properties;
|
||||
d=f=0;for(c=e.length;f<c;d=++f)if(oa=e[d],oa.soak)return oa.soak=!1,f=new b(n.base,n.properties.slice(0,d)),c=new b(n.base,n.properties.slice(d)),f.isComplex()&&(d=new z(a.scope.freeVariable("ref")),f=new D(new V(d,f)),c.base=d),new E(new F(f),c,{soak:!0});return!1}}(this)()};return b}(a);e.Comment=G=function(a){function b(a){this.comment=a}na(b,a);b.prototype.isStatement=fa;b.prototype.makeReturn=ea;b.prototype.compileNode=function(a,b){var f;f=this.comment.replace(/^(\s*)#(?=\s)/gm,"$1 *");f="/*"+
|
||||
Na(f,this.tab)+(0<=Ha.call(f,"\n")?"\n"+this.tab:"")+" */";(b||a.level)===u&&(f=a.indent+f);return[this.makeCode("\n"),this.makeCode(f)]};return b}(a);e.Call=g=function(a){function b(a,b,f){this.variable=a;this.args=null!=b?b:[];this.soak=f;this.isNew=!1;this.variable instanceof L&&this.variable.isNotCallable()&&this.variable.error("literal is not a function")}na(b,a);b.prototype.children=["variable","args"];b.prototype.updateLocationDataIfMissing=function(a){var n,f;this.locationData&&this.needsUpdatedStartLocation&&
|
||||
(this.locationData.first_line=a.first_line,this.locationData.first_column=a.first_column,n=(null!=(f=this.variable)?f.base:void 0)||this.variable,n.needsUpdatedStartLocation&&(this.variable.locationData.first_line=a.first_line,this.variable.locationData.first_column=a.first_column,n.updateLocationDataIfMissing(a)),delete this.needsUpdatedStartLocation);return b.__super__.updateLocationDataIfMissing.apply(this,arguments)};b.prototype.newInstance=function(){var a,c;a=(null!=(c=this.variable)?c.base:
|
||||
void 0)||this.variable;a instanceof b&&!a.isNew?a.newInstance():this.isNew=!0;this.needsUpdatedStartLocation=!0;return this};b.prototype.unfoldSoak=function(a){var n,f,d,c,e;if(this.soak){if(this instanceof ja)n=new B(this.superReference(a)),f=new L(n);else{if(f=Ka(a,this,"variable"))return f;f=(new L(this.variable)).cacheReference(a);n=f[0];f=f[1]}f=new b(f,this.args);f.isNew=this.isNew;n=new B("typeof "+n.compile(a)+' \x3d\x3d\x3d "function"');return new E(n,new L(f),{soak:!0})}n=this;for(d=[];;)if(n.variable instanceof
|
||||
b)d.push(n),n=n.variable;else{if(!(n.variable instanceof L))break;d.push(n);if(!((n=n.variable.base)instanceof b))break}e=d.reverse();d=0;for(c=e.length;d<c;d++)n=e[d],f&&(n.variable instanceof b?n.variable=f:n.variable.base=f),f=Ka(a,n,"variable");return f};b.prototype.compileNode=function(a){var b,f,d,n,c,e;null!=(d=this.variable)&&(d.front=this.front);d=Q.compileSplattedArray(a,this.args,!0);if(d.length)return this.compileSplat(a,d);d=[];e=this.args;f=n=0;for(c=e.length;n<c;f=++n)b=e[f],f&&d.push(this.makeCode(", ")),
|
||||
d.push.apply(d,b.compileToFragments(a,h));b=[];this instanceof ja?(a=this.superReference(a)+(".call("+this.superThis(a)),d.length&&(a+=", "),b.push(this.makeCode(a))):(this.isNew&&b.push(this.makeCode("new ")),b.push.apply(b,this.variable.compileToFragments(a,q)),b.push(this.makeCode("(")));b.push.apply(b,d);b.push(this.makeCode(")"));return b};b.prototype.compileSplat=function(a,b){var f,d,n,c;if(this instanceof ja)return[].concat(this.makeCode(this.superReference(a)+".apply("+this.superThis(a)+
|
||||
", "),b,this.makeCode(")"));if(this.isNew)return f=this.tab+da,[].concat(this.makeCode("(function(func, args, ctor) {\n"+f+"ctor.prototype \x3d func.prototype;\n"+f+"var child \x3d new ctor, result \x3d func.apply(child, args);\n"+f+"return Object(result) \x3d\x3d\x3d result ? result : child;\n"+this.tab+"})("),this.variable.compileToFragments(a,h),this.makeCode(", "),b,this.makeCode(", function(){})"));f=[];d=new L(this.variable);(n=d.properties.pop())&&d.isComplex()?(c=a.scope.freeVariable("ref"),
|
||||
f=f.concat(this.makeCode("("+c+" \x3d "),d.compileToFragments(a,h),this.makeCode(")"),n.compileToFragments(a))):(d=d.compileToFragments(a,q),aa.test(Ca(d))&&(d=this.wrapInBraces(d)),n?(c=Ca(d),d.push.apply(d,n.compileToFragments(a))):c="null",f=f.concat(d));return f.concat(this.makeCode(".apply("+c+", "),b,this.makeCode(")"))};return b}(a);e.SuperCall=ja=function(a){function b(a){b.__super__.constructor.call(this,null,null!=a?a:[new Q(new z("arguments"))]);this.isBare=null!=a}na(b,a);b.prototype.superReference=
|
||||
function(a){var b,f,d,c,n,e,g;c=a.scope.namedMethod();if(null!=c&&c.klass){d=c.klass;n=c.name;g=c.variable;d.isComplex()&&(f=new z(a.scope.parent.freeVariable("base")),b=new L(new D(new V(f,d))),g.base=b,g.properties.splice(0,d.properties.length));if(n.isComplex()||n instanceof k&&n.index.isAssignable())e=new z(a.scope.parent.freeVariable("name")),n=new k(new V(e,n.index)),g.properties.pop(),g.properties.push(n);b=[new va(new P("__super__"))];c["static"]&&b.push(new va(new P("constructor")));b.push(null!=
|
||||
e?new k(e):n);return(new L(null!=f?f:d,b)).compile(a)}return null!=c&&c.ctor?c.name+".__super__.constructor":this.error("cannot call super outside of an instance method.")};b.prototype.superThis=function(a){return(a=a.scope.method)&&!a.klass&&a.context||"this"};return b}(g);e.RegexWithInterpolations=function(a){function b(a){null==a&&(a=[]);b.__super__.constructor.call(this,new L(new z("RegExp")),a,!1)}na(b,a);return b}(g);e.TaggedTemplateCall=function(a){function b(a,oa,f){oa instanceof Za&&(oa=
|
||||
new Ua(c.wrap([new L(oa)])));b.__super__.constructor.call(this,a,[oa],f)}na(b,a);b.prototype.compileNode=function(a){a.inTaggedTemplateCall=!0;return this.variable.compileToFragments(a,q).concat(this.args[0].compileToFragments(a,h))};return b}(g);e.Extends=M=function(a){function b(a,b){this.child=a;this.parent=b}na(b,a);b.prototype.children=["child","parent"];b.prototype.compileToFragments=function(a){return(new g(new L(new B(ya("extend",a))),[this.child,this.parent])).compileToFragments(a)};return b}(a);
|
||||
e.Access=va=function(a){function b(a,b){this.name=a;this.soak="soak"===b}na(b,a);b.prototype.children=["name"];b.prototype.compileToFragments=function(a){var b,f;a=this.name.compileToFragments(a);b=this.name.unwrap();return b instanceof P?(f=b.value,0<=Ha.call(m,f))?[this.makeCode('["')].concat(Aa.call(a),[this.makeCode('"]')]):[this.makeCode(".")].concat(Aa.call(a)):[this.makeCode("[")].concat(Aa.call(a),[this.makeCode("]")])};b.prototype.isComplex=H;return b}(a);e.Index=k=function(a){function b(a){this.index=
|
||||
a}na(b,a);b.prototype.children=["index"];b.prototype.compileToFragments=function(a){return[].concat(this.makeCode("["),this.index.compileToFragments(a,O),this.makeCode("]"))};b.prototype.isComplex=function(){return this.index.isComplex()};return b}(a);e.Range=Y=function(a){function b(a,b,f){this.from=a;this.to=b;this.equals=(this.exclusive="exclusive"===f)?"":"\x3d"}na(b,a);b.prototype.children=["from","to"];b.prototype.compileVariables=function(a){var b,f;a=Fa(a,{top:!0});b=X(a,"isComplex");f=this.cacheToCodeFragments(this.from.cache(a,
|
||||
h,b));this.fromC=f[0];this.fromVar=f[1];f=this.cacheToCodeFragments(this.to.cache(a,h,b));this.toC=f[0];this.toVar=f[1];if(f=X(a,"step"))a=this.cacheToCodeFragments(f.cache(a,h,b)),this.step=a[0],this.stepVar=a[1];this.fromNum=this.from.isNumber()?Number(this.fromVar):null;this.toNum=this.to.isNumber()?Number(this.toVar):null;return this.stepNum=null!=f&&f.isNumber()?Number(this.stepVar):null};b.prototype.compileNode=function(a){var b,f,d,c,n,e,g,h,k,m;this.fromVar||this.compileVariables(a);if(!a.index)return this.compileArray(a);
|
||||
e=null!=this.fromNum&&null!=this.toNum;n=X(a,"index");g=(a=X(a,"name"))&&a!==n;m=n+" \x3d "+this.fromC;this.toC!==this.toVar&&(m+=", "+this.toC);this.step!==this.stepVar&&(m+=", "+this.step);c=[n+" \x3c"+this.equals,n+" \x3e"+this.equals];f=c[0];c=c[1];f=null!=this.stepNum?0<this.stepNum?f+" "+this.toVar:c+" "+this.toVar:e?(h=[this.fromNum,this.toNum],d=h[0],k=h[1],h,d<=k?f+" "+k:c+" "+k):(b=this.stepVar?this.stepVar+" \x3e 0":this.fromVar+" \x3c\x3d "+this.toVar,b+" ? "+f+" "+this.toVar+" : "+c+
|
||||
" "+this.toVar);b=this.stepVar?n+" +\x3d "+this.stepVar:e?g?d<=k?"++"+n:"--"+n:d<=k?n+"++":n+"--":g?b+" ? ++"+n+" : --"+n:b+" ? "+n+"++ : "+n+"--";g&&(m=a+" \x3d "+m);g&&(b=a+" \x3d "+b);return[this.makeCode(m+"; "+f+"; "+b)]};b.prototype.compileArray=function(a){var b,f,d,c,n,e,g,h,k;if((f=null!=this.fromNum&&null!=this.toNum)&&20>=Math.abs(this.fromNum-this.toNum))return b=function(){h=[];for(var a=e=this.fromNum,b=this.toNum;e<=b?a<=b:a>=b;e<=b?a++:a--)h.push(a);return h}.apply(this),this.exclusive&&
|
||||
b.pop(),[this.makeCode("["+b.join(", ")+"]")];c=this.tab+da;d=a.scope.freeVariable("i",{single:!0});g=a.scope.freeVariable("results");n="\n"+c+g+" \x3d [];";f?(a.index=d,f=Ca(this.compileNode(a))):(k=d+" \x3d "+this.fromC+(this.toC!==this.toVar?", "+this.toC:""),f=this.fromVar+" \x3c\x3d "+this.toVar,f="var "+k+"; "+f+" ? "+d+" \x3c"+this.equals+" "+this.toVar+" : "+d+" \x3e"+this.equals+" "+this.toVar+"; "+f+" ? "+d+"++ : "+d+"--");d="{ "+g+".push("+d+"); }\n"+c+"return "+g+";\n"+a.indent;a=function(a){return null!=
|
||||
a?a.contains(gb):void 0};if(a(this.from)||a(this.to))b=", arguments";return[this.makeCode("(function() {"+n+"\n"+c+"for ("+f+")"+d+"}).apply(this"+(null!=b?b:"")+")")]};return b}(a);e.Slice=ca=function(a){function b(a){this.range=a;b.__super__.constructor.call(this)}na(b,a);b.prototype.children=["range"];b.prototype.compileNode=function(a){var b,f,d,c,n;b=this.range;c=b.to;d=(b=b.from)&&b.compileToFragments(a,O)||[this.makeCode("0")];c&&(b=c.compileToFragments(a,O),f=Ca(b),this.range.exclusive||-1!==
|
||||
+f)&&(n=", "+(this.range.exclusive?f:c.isNumber()?""+(+f+1):(b=c.compileToFragments(a,q),"+"+Ca(b)+" + 1 || 9e9")));return[this.makeCode(".slice("+Ca(d)+(n||"")+")")]};return b}(a);e.Obj=C=function(a){function b(a,b){this.generated=null!=b?b:!1;this.objects=this.properties=a||[]}na(b,a);b.prototype.children=["properties"];b.prototype.compileNode=function(a){var b,f,d,c,n,e,g,h,k,m,q,r,p;p=this.properties;if(this.generated)for(f=0,b=p.length;f<b;f++)d=p[f],d instanceof L&&d.error("cannot have an implicit value in an implicit object");
|
||||
f=b=0;for(d=p.length;b<d&&!(r=p[f],(r.variable||r).base instanceof D);f=++b);d=f<p.length;n=a.indent+=da;k=this.lastNonComment(this.properties);b=[];d&&(q=a.scope.freeVariable("obj"),b.push(this.makeCode("(\n"+n+q+" \x3d ")));b.push(this.makeCode("{"+(0===p.length||0===f?"}":"\n")));c=h=0;for(m=p.length;h<m;c=++h)r=p[c],c===f&&(0!==c&&b.push(this.makeCode("\n"+n+"}")),b.push(this.makeCode(",\n"))),g=c===p.length-1||c===f-1?"":r===k||r instanceof G?"\n":",\n",e=r instanceof G?"":n,d&&c<f&&(e+=da),
|
||||
r instanceof V&&("object"!==r.context&&r.operatorToken.error("unexpected "+r.operatorToken.value),r.variable instanceof L&&r.variable.hasProperties()&&r.variable.error("invalid object key")),r instanceof L&&r["this"]&&(r=new V(r.properties[0].name,r,"object")),r instanceof G||(c<f?r instanceof V||(r=new V(r,r,"object")):(r instanceof V?(c=r.variable,r=r.value):(r=r.base.cache(a),c=r[0],r=r[1],c instanceof z&&(c=new P(c.value))),r=new V(new L(new z(q),[new va(c)]),r))),e&&b.push(this.makeCode(e)),
|
||||
b.push.apply(b,r.compileToFragments(a,u)),g&&b.push(this.makeCode(g));d?b.push(this.makeCode(",\n"+n+q+"\n"+this.tab+")")):0!==p.length&&b.push(this.makeCode("\n"+this.tab+"}"));return this.front&&!d?this.wrapInBraces(b):b};b.prototype.assigns=function(a){var b,f,d,c;c=this.properties;b=0;for(f=c.length;b<f;b++)if(d=c[b],d.assigns(a))return!0;return!1};return b}(a);e.Arr=pa=function(a){function b(a){this.objects=a||[]}na(b,a);b.prototype.children=["objects"];b.prototype.compileNode=function(a){var b,
|
||||
f,d,c,n;if(!this.objects.length)return[this.makeCode("[]")];a.indent+=da;b=Q.compileSplattedArray(a,this.objects);if(b.length)return b;b=[];var e;n=this.objects;e=[];d=0;for(c=n.length;d<c;d++)f=n[d],e.push(f.compileToFragments(a,h));d=c=0;for(n=e.length;c<n;d=++c)f=e[d],d&&b.push(this.makeCode(", ")),b.push.apply(b,f);0<=Ca(b).indexOf("\n")?(b.unshift(this.makeCode("[\n"+a.indent)),b.push(this.makeCode("\n"+this.tab+"]"))):(b.unshift(this.makeCode("[")),b.push(this.makeCode("]")));return b};b.prototype.assigns=
|
||||
function(a){var b,f,d,c;c=this.objects;b=0;for(f=c.length;b<f;b++)if(d=c[b],d.assigns(a))return!0;return!1};return b}(a);e.Class=v=function(a){function b(a,b,f){this.variable=a;this.parent=b;this.body=null!=f?f:new c;this.boundFuncs=[];this.body.classBody=!0}na(b,a);b.prototype.children=["variable","parent","body"];b.prototype.defaultClassVariableName="_Class";b.prototype.determineName=function(){var a,b;if(!this.variable)return this.defaultClassVariableName;b=this.variable.properties;b=(a=b[b.length-
|
||||
1])?a instanceof va&&a.name:this.variable.base;if(!(b instanceof z||b instanceof P))return this.defaultClassVariableName;b=b.value;a||(a=Ga(b))&&this.variable.error(a);return 0<=Ha.call(m,b)?"_"+b:b};b.prototype.setContext=function(a){return this.body.traverseChildren(!1,function(b){if(b.classBody)return!1;if(b instanceof ha)return b.value=a;if(b instanceof p&&b.bound)return b.context=a})};b.prototype.addBoundFunctions=function(a){var b,f,d,c;c=this.boundFuncs;f=0;for(d=c.length;f<d;f++)b=c[f],b=
|
||||
(new L(new ha,[new va(b)])).compile(a),this.ctor.body.unshift(new B(b+" \x3d "+ya("bind",a)+"("+b+", this)"))};b.prototype.addProperties=function(a,b,f){var d,c,n,e;e=a.base.properties.slice(0);var g;for(g=[];d=e.shift();)d instanceof V&&(c=d.variable.base,delete d.context,n=d.value,"constructor"===c.value?(this.ctor&&d.error("cannot define more than one constructor in a class"),n.bound&&d.error("cannot define a constructor as a bound function"),n instanceof p?d=this.ctor=n:(this.externalCtor=f.classScope.freeVariable("ctor"),
|
||||
d=new V(new z(this.externalCtor),n))):d.variable["this"]?n["static"]=!0:(a=c.isComplex()?new k(c):new va(c),d.variable=new L(new z(b),[new va(new P("prototype")),a]),n instanceof p&&n.bound&&(this.boundFuncs.push(c),n.bound=!1))),g.push(d);return ra(g)};b.prototype.walkBody=function(a,e){return this.traverseChildren(!1,function(f){return function(d){var n,g,oa,h,k,m,q;n=!0;if(d instanceof b)return!1;if(d instanceof c){q=g=d.expressions;oa=h=0;for(k=q.length;h<k;oa=++h)m=q[oa],m instanceof V&&m.variable.looksStatic(a)?
|
||||
m.value["static"]=!0:m instanceof L&&m.isObject(!0)&&(n=!1,g[oa]=f.addProperties(m,a,e));d.expressions=ma(g)}return n&&!(d instanceof b)}}(this))};b.prototype.hoistDirectivePrologue=function(){var a,b,f;b=0;for(a=this.body.expressions;(f=a[b])&&f instanceof G||f instanceof L&&f.isString();)++b;return this.directives=a.splice(0,b)};b.prototype.ensureConstructor=function(a){this.ctor||(this.ctor=new p,this.externalCtor?this.ctor.body.push(new B(this.externalCtor+".apply(this, arguments)")):this.parent&&
|
||||
this.ctor.body.push(new B(a+".__super__.constructor.apply(this, arguments)")),this.ctor.body.makeReturn(),this.body.expressions.unshift(this.ctor));this.ctor.ctor=this.ctor.name=a;this.ctor.klass=null;return this.ctor.noReturn=!0};b.prototype.compileNode=function(a){var b,f,d,n,e;(f=this.body.jumps())&&f.error("Class bodies cannot contain pure statements");(b=this.body.contains(gb))&&b.error("Class bodies shouldn't reference arguments");e=this.determineName();n=new z(e);f=new p([],c.wrap([this.body]));
|
||||
b=[];a.classScope=f.makeScope(a.scope);this.hoistDirectivePrologue();this.setContext(e);this.walkBody(e,a);this.ensureConstructor(e);this.addBoundFunctions(a);this.body.spaced=!0;this.body.expressions.push(n);this.parent&&(e=new z(a.classScope.freeVariable("superClass",{reserve:!1})),this.body.expressions.unshift(new M(n,e)),f.params.push(new W(e)),b.push(this.parent));(d=this.body.expressions).unshift.apply(d,this.directives);d=new D(new g(f,b));this.variable&&(d=new V(this.variable,d,null,{moduleDeclaration:this.moduleDeclaration}));
|
||||
return d.compileToFragments(a)};return b}(a);e.ModuleDeclaration=w=function(a){function b(a,b){this.clause=a;this.source=b;this.checkSource()}na(b,a);b.prototype.children=["clause","source"];b.prototype.isStatement=fa;b.prototype.jumps=ea;b.prototype.makeReturn=ea;b.prototype.checkSource=function(){if(null!=this.source&&this.source instanceof Ua)return this.source.error("the name of the module to be imported from must be an uninterpolated string")};b.prototype.checkScope=function(a,b){if(0!==a.indent.length)return this.error(b+
|
||||
" statements must be at top-level scope")};return b}(a);e.ImportDeclaration=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);b.prototype.compileNode=function(a){var b,f;this.checkScope(a,"import");a.importedSymbols=[];b=[];b.push(this.makeCode(this.tab+"import "));null!=this.clause&&b.push.apply(b,this.clause.compileNode(a));null!=(null!=(f=this.source)?f.value:void 0)&&(null!==this.clause&&b.push(this.makeCode(" from ")),b.push(this.makeCode(this.source.value)));
|
||||
b.push(this.makeCode(";"));return b};return b}(w);e.ImportClause=function(a){function b(a,b){this.defaultBinding=a;this.namedImports=b}na(b,a);b.prototype.children=["defaultBinding","namedImports"];b.prototype.compileNode=function(a){var b;b=[];null!=this.defaultBinding&&(b.push.apply(b,this.defaultBinding.compileNode(a)),null!=this.namedImports&&b.push(this.makeCode(", ")));null!=this.namedImports&&b.push.apply(b,this.namedImports.compileNode(a));return b};return b}(a);e.ExportDeclaration=w=function(a){function b(){return b.__super__.constructor.apply(this,
|
||||
arguments)}na(b,a);b.prototype.compileNode=function(a){var b,f;this.checkScope(a,"export");b=[];b.push(this.makeCode(this.tab+"export "));this instanceof K&&b.push(this.makeCode("default "));this instanceof K||!(this.clause instanceof V||this.clause instanceof v)||(this.clause instanceof v&&!this.clause.variable&&this.clause.error("anonymous classes cannot be exported"),b.push(this.makeCode("var ")),this.clause.moduleDeclaration="export");b=null!=this.clause.body&&this.clause.body instanceof c?b.concat(this.clause.compileToFragments(a,
|
||||
u)):b.concat(this.clause.compileNode(a));null!=(null!=(f=this.source)?f.value:void 0)&&b.push(this.makeCode(" from "+this.source.value));b.push(this.makeCode(";"));return b};return b}(w);e.ExportNamedDeclaration=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);return b}(w);e.ExportDefaultDeclaration=K=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);return b}(w);e.ExportAllDeclaration=function(a){function b(){return b.__super__.constructor.apply(this,
|
||||
arguments)}na(b,a);return b}(w);e.ModuleSpecifierList=w=function(a){function b(a){this.specifiers=a}na(b,a);b.prototype.children=["specifiers"];b.prototype.compileNode=function(a){var b,f,d,c,e;b=[];a.indent+=da;var n;e=this.specifiers;n=[];d=0;for(c=e.length;d<c;d++)f=e[d],n.push(f.compileToFragments(a,h));if(0!==this.specifiers.length){b.push(this.makeCode("{\n"+a.indent));d=c=0;for(e=n.length;c<e;d=++c)f=n[d],d&&b.push(this.makeCode(",\n"+a.indent)),b.push.apply(b,f);b.push(this.makeCode("\n}"))}else b.push(this.makeCode("{}"));
|
||||
return b};return b}(a);e.ImportSpecifierList=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);return b}(w);e.ExportSpecifierList=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);return b}(w);e.ModuleSpecifier=T=function(a){function b(a,b,f){this.original=a;this.alias=b;this.moduleDeclarationType=f;this.identifier=null!=this.alias?this.alias.value:this.original.value}na(b,a);b.prototype.children=["original","alias"];b.prototype.compileNode=
|
||||
function(a){a.scope.find(this.identifier,this.moduleDeclarationType);a=[];a.push(this.makeCode(this.original.value));null!=this.alias&&a.push(this.makeCode(" as "+this.alias.value));return a};return b}(a);e.ImportSpecifier=w=function(a){function b(a,c){b.__super__.constructor.call(this,a,c,"import")}na(b,a);b.prototype.compileNode=function(a){var c;(c=this.identifier,0<=Ha.call(a.importedSymbols,c))||a.scope.check(this.identifier)?this.error("'"+this.identifier+"' has already been declared"):a.importedSymbols.push(this.identifier);
|
||||
return b.__super__.compileNode.call(this,a)};return b}(T);e.ImportDefaultSpecifier=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);return b}(w);e.ImportNamespaceSpecifier=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);return b}(w);e.ExportSpecifier=function(a){function b(a,c){b.__super__.constructor.call(this,a,c,"export")}na(b,a);return b}(T);e.Assign=V=function(a){function b(a,b,f,d){this.variable=a;this.value=b;this.context=
|
||||
f;null==d&&(d={});this.param=d.param;this.subpattern=d.subpattern;this.operatorToken=d.operatorToken;this.moduleDeclaration=d.moduleDeclaration}na(b,a);b.prototype.children=["variable","value"];b.prototype.isStatement=function(a){return(null!=a?a.level:void 0)===u&&null!=this.context&&(this.moduleDeclaration||0<=Ha.call(this.context,"?"))};b.prototype.checkAssignability=function(a,b){if(Object.prototype.hasOwnProperty.call(a.scope.positions,b.value)&&"import"===a.scope.variables[a.scope.positions[b.value]].type)return b.error("'"+
|
||||
b.value+"' is read-only")};b.prototype.assigns=function(a){return this["object"===this.context?"value":"variable"].assigns(a)};b.prototype.unfoldSoak=function(a){return Ka(a,this,"variable")};b.prototype.compileNode=function(a){var b,f,d,c,e,g,n;if(f=this.variable instanceof L){if(this.variable.isArray()||this.variable.isObject())return this.compilePatternMatch(a);if(this.variable.isSplice())return this.compileSplice(a);if("||\x3d"===(c=this.context)||"\x26\x26\x3d"===c||"?\x3d"===c)return this.compileConditional(a);
|
||||
if("**\x3d"===(e=this.context)||"//\x3d"===e||"%%\x3d"===e)return this.compileSpecialMath(a)}this.value instanceof p&&(this.value["static"]?(this.value.klass=this.variable.base,this.value.name=this.variable.properties[0],this.value.variable=this.variable):2<=(null!=(g=this.variable.properties)?g.length:void 0)&&(g=this.variable.properties,c=3<=g.length?Aa.call(g,0,d=g.length-2):(d=0,[]),e=g[d++],d=g[d++],"prototype"===(null!=(n=e.name)?n.value:void 0)&&(this.value.klass=new L(this.variable.base,c),
|
||||
this.value.name=d,this.value.variable=this.variable)));this.context||(n=this.variable.unwrapAll(),n.isAssignable()||this.variable.error("'"+this.variable.compile(a)+"' can't be assigned"),"function"===typeof n.hasProperties&&n.hasProperties()||(this.moduleDeclaration?(this.checkAssignability(a,n),a.scope.add(n.value,this.moduleDeclaration)):this.param?a.scope.add(n.value,"var"):(this.checkAssignability(a,n),a.scope.find(n.value))));n=this.value.compileToFragments(a,h);f&&this.variable.base instanceof
|
||||
C&&(this.variable.front=!0);f=this.variable.compileToFragments(a,h);if("object"===this.context){if(b=Ca(f),0<=Ha.call(m,b))f.unshift(this.makeCode('"')),f.push(this.makeCode('"'));return f.concat(this.makeCode(": "),n)}b=f.concat(this.makeCode(" "+(this.context||"\x3d")+" "),n);return a.level<=h?b:this.wrapInBraces(b)};b.prototype.compilePatternMatch=function(a){var c,f,d,e,g,n,m,q,r,p,l,t,w,D,C,v;D=a.level===u;q=this.value;t=this.variable.base.objects;if(!(w=t.length))return f=q.compileToFragments(a),
|
||||
a.level>=y?this.wrapInBraces(f):f;l=t[0];1===w&&l instanceof x&&l.error("Destructuring assignment has no target");n=this.variable.isObject();if(D&&1===w&&!(l instanceof Q))return d=null,l instanceof b&&"object"===l.context?(f=l,e=f.variable,g=e.base,l=f.value,l instanceof b&&(d=l.value,l=l.variable)):(l instanceof b&&(d=l.value,l=l.variable),g=n?l["this"]?l.properties[0].name:new P(l.unwrap().value):new R(0)),c=g.unwrap()instanceof P,q=new L(q),q.properties.push(new (c?va:k)(g)),(p=Ga(l.unwrap().value))&&
|
||||
l.error(p),d&&(q=new A("?",q,d)),(new b(l,q,null,{param:this.param})).compileToFragments(a,u);C=q.compileToFragments(a,h);v=Ca(C);f=[];e=!1;q.unwrap()instanceof z&&!this.variable.assigns(v)||(f.push([this.makeCode((d=a.scope.freeVariable("ref"))+" \x3d ")].concat(Aa.call(C))),C=[this.makeCode(d)],v=d);d=q=0;for(r=t.length;q<r;d=++q){l=t[d];g=d;if(!e&&l instanceof Q)p=l.name.unwrap().value,l=l.unwrap(),g=w+" \x3c\x3d "+v+".length ? "+ya("slice",a)+".call("+v+", "+d,(c=w-d-1)?(m=a.scope.freeVariable("i",
|
||||
{single:!0}),g+=", "+m+" \x3d "+v+".length - "+c+") : ("+m+" \x3d "+d+", [])"):g+=") : []",g=new B(g),e=m+"++";else if(!e&&l instanceof x){if(c=w-d-1)1===c?e=v+".length - 1":(m=a.scope.freeVariable("i",{single:!0}),g=new B(m+" \x3d "+v+".length - "+c),e=m+"++",f.push(g.compileToFragments(a,h)));continue}else(l instanceof Q||l instanceof x)&&l.error("multiple splats/expansions are disallowed in an assignment"),d=null,l instanceof b&&"object"===l.context?(g=l.variable,g=g.base,l=l.value,l instanceof
|
||||
b&&(d=l.value,l=l.variable)):(l instanceof b&&(d=l.value,l=l.variable),g=n?l["this"]?l.properties[0].name:new P(l.unwrap().value):new B(e||g)),p=l.unwrap().value,c=g.unwrap()instanceof P,g=new L(new B(v),[new (c?va:k)(g)]),d&&(g=new A("?",g,d));null!=p&&(p=Ga(p))&&l.error(p);f.push((new b(l,g,null,{param:this.param,subpattern:!0})).compileToFragments(a,h))}D||this.subpattern||f.push(C);f=this.joinFragmentArrays(f,", ");return a.level<h?f:this.wrapInBraces(f)};b.prototype.compileConditional=function(a){var c,
|
||||
f;f=this.variable.cacheReference(a);c=f[0];f=f[1];c.properties.length||!(c.base instanceof B)||c.base instanceof ha||a.scope.check(c.base.value)||this.variable.error('the variable "'+c.base.value+"\" can't be assigned with "+this.context+" because it has not been declared before");if(0<=Ha.call(this.context,"?"))return a.isExistentialEquals=!0,(new E(new F(c),f,{type:"if"})).addElse(new b(f,this.value,"\x3d")).compileToFragments(a);c=(new A(this.context.slice(0,-1),c,new b(f,this.value,"\x3d"))).compileToFragments(a);
|
||||
return a.level<=h?c:this.wrapInBraces(c)};b.prototype.compileSpecialMath=function(a){var c,f;f=this.variable.cacheReference(a);c=f[0];f=f[1];return(new b(c,new A(this.context.slice(0,-1),f,this.value))).compileToFragments(a)};b.prototype.compileSplice=function(a){var b,f,d,c,e,g;c=this.variable.properties.pop().range;d=c.from;b=c.to;f=c.exclusive;g=this.variable.compile(a);d?(e=this.cacheToCodeFragments(d.cache(a,y)),c=e[0],e=e[1]):c=e="0";b?null!=d&&d.isNumber()&&b.isNumber()?(b=b.compile(a)-e,f||
|
||||
(b+=1)):(b=b.compile(a,q)+" - "+e,f||(b+=" + 1")):b="9e9";f=this.value.cache(a,h);d=f[0];f=f[1];b=[].concat(this.makeCode("[].splice.apply("+g+", ["+c+", "+b+"].concat("),d,this.makeCode(")), "),f);return a.level>u?this.wrapInBraces(b):b};return b}(a);e.Code=p=function(a){function b(a,b,f){this.params=a||[];this.body=b||new c;this.bound="boundfunc"===f;this.isGenerator=!!this.body.contains(function(a){return a instanceof A&&a.isYield()||a instanceof qa})}na(b,a);b.prototype.children=["params","body"];
|
||||
b.prototype.isStatement=function(){return!!this.ctor};b.prototype.jumps=H;b.prototype.makeScope=function(a){return new J(a,this.body,this)};b.prototype.compileNode=function(a){var e,f,d,n,h,k,m,r,l,p,y,u,t;this.bound&&null!=(f=a.scope.method)&&f.bound&&(this.context=a.scope.method.context);if(this.bound&&!this.context)return this.context="_this",f=new b([new W(new z(this.context))],new c([this])),f=new g(f,[new ha]),f.updateLocationDataIfMissing(this.locationData),f.compileNode(a);a.scope=X(a,"classScope")||
|
||||
this.makeScope(a.scope);a.scope.shared=X(a,"sharedScope");a.indent+=da;delete a.bare;delete a.isExistentialEquals;f=[];e=[];r=this.params;n=0;for(k=r.length;n<k;n++)m=r[n],m instanceof x||a.scope.parameter(m.asReference(a));r=this.params;n=0;for(k=r.length;n<k;n++)if(m=r[n],m.splat||m instanceof x){n=this.params;h=0;for(m=n.length;h<m;h++)l=n[h],l instanceof x||!l.name.value||a.scope.add(l.name.value,"var",!0);h=new V(new L(new pa(function(){var b,d,f,c;f=this.params;c=[];d=0;for(b=f.length;d<b;d++)l=
|
||||
f[d],c.push(l.asReference(a));return c}.call(this))),new L(new z("arguments")));break}y=this.params;r=0;for(n=y.length;r<n;r++)m=y[r],m.isComplex()?(t=p=m.asReference(a),m.value&&(t=new A("?",p,m.value)),e.push(new V(new L(m.name),t,"\x3d",{param:!0}))):(p=m,m.value&&(k=new B(p.name.value+" \x3d\x3d null"),t=new V(new L(m.name),m.value,"\x3d"),e.push(new E(k,t)))),h||f.push(p);m=this.body.isEmpty();h&&e.unshift(h);e.length&&(d=this.body.expressions).unshift.apply(d,e);d=h=0;for(e=f.length;h<e;d=++h)l=
|
||||
f[d],f[d]=l.compileToFragments(a),a.scope.parameter(Ca(f[d]));u=[];this.eachParamName(function(a,b){0<=Ha.call(u,a)&&b.error("multiple parameters named "+a);return u.push(a)});m||this.noReturn||this.body.makeReturn();d="function";this.isGenerator&&(d+="*");this.ctor&&(d+=" "+this.name);e=[this.makeCode(d+"(")];d=m=0;for(h=f.length;m<h;d=++m)l=f[d],d&&e.push(this.makeCode(", ")),e.push.apply(e,l);e.push(this.makeCode(") {"));this.body.isEmpty()||(e=e.concat(this.makeCode("\n"),this.body.compileWithDeclarations(a),
|
||||
this.makeCode("\n"+this.tab)));e.push(this.makeCode("}"));return this.ctor?[this.makeCode(this.tab)].concat(Aa.call(e)):this.front||a.level>=q?this.wrapInBraces(e):e};b.prototype.eachParamName=function(a){var b,f,d,c,e;c=this.params;e=[];b=0;for(f=c.length;b<f;b++)d=c[b],e.push(d.eachName(a));return e};b.prototype.traverseChildren=function(a,c){if(a)return b.__super__.traverseChildren.call(this,a,c)};return b}(a);e.Param=W=function(a){function b(a,b,f){this.name=a;this.value=b;this.splat=f;(a=Ga(this.name.unwrapAll().value))&&
|
||||
this.name.error(a);this.name instanceof C&&this.name.generated&&(a=this.name.objects[0].operatorToken,a.error("unexpected "+a.value))}na(b,a);b.prototype.children=["name","value"];b.prototype.compileToFragments=function(a){return this.name.compileToFragments(a,h)};b.prototype.asReference=function(a){var b;if(this.reference)return this.reference;b=this.name;b["this"]?(b=b.properties[0].name.value,0<=Ha.call(m,b)&&(b="_"+b),b=new z(a.scope.freeVariable(b))):b.isComplex()&&(b=new z(a.scope.freeVariable("arg")));
|
||||
b=new L(b);this.splat&&(b=new Q(b));b.updateLocationDataIfMissing(this.locationData);return this.reference=b};b.prototype.isComplex=function(){return this.name.isComplex()};b.prototype.eachName=function(a,b){var f,d,c,e;null==b&&(b=this.name);f=function(b){return a("@"+b.properties[0].name.value,b)};if(b instanceof B)return a(b.value,b);if(b instanceof L)return f(b);b=null!=(d=b.objects)?d:[];d=0;for(c=b.length;d<c;d++)e=b[d],e instanceof V&&null==e.context&&(e=e.variable),e instanceof V?(e.value instanceof
|
||||
V&&(e=e.value),this.eachName(a,e.value.unwrap())):e instanceof Q?(e=e.name.unwrap(),a(e.value,e)):e instanceof L?e.isArray()||e.isObject()?this.eachName(a,e.base):e["this"]?f(e):a(e.base.value,e.base):e instanceof x||e.error("illegal parameter "+e.compile())};return b}(a);e.Splat=Q=function(a){function b(a){this.name=a.compile?a:new B(a)}na(b,a);b.prototype.children=["name"];b.prototype.isAssignable=fa;b.prototype.assigns=function(a){return this.name.assigns(a)};b.prototype.compileToFragments=function(a){return this.name.compileToFragments(a)};
|
||||
b.prototype.unwrap=function(){return this.name};b.compileSplattedArray=function(a,c,f){var d,e,g,n,m,k;for(n=-1;(d=c[++n])&&!(d instanceof b););if(n>=c.length)return[];if(1===c.length)return d=c[0],c=d.compileToFragments(a,h),f?c:[].concat(d.makeCode(ya("slice",a)+".call("),c,d.makeCode(")"));f=c.slice(n);g=m=0;for(k=f.length;m<k;g=++m)d=f[g],e=d.compileToFragments(a,h),f[g]=d instanceof b?[].concat(d.makeCode(ya("slice",a)+".call("),e,d.makeCode(")")):[].concat(d.makeCode("["),e,d.makeCode("]"));
|
||||
if(0===n)return d=c[0],a=d.joinFragmentArrays(f.slice(1),", "),f[0].concat(d.makeCode(".concat("),a,d.makeCode(")"));m=c.slice(0,n);k=[];e=0;for(g=m.length;e<g;e++)d=m[e],k.push(d.compileToFragments(a,h));d=c[0].joinFragmentArrays(k,", ");a=c[n].joinFragmentArrays(f,", ");f=c[c.length-1];return[].concat(c[0].makeCode("["),d,c[n].makeCode("].concat("),a,f.makeCode(")"))};return b}(a);e.Expansion=x=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);b.prototype.isComplex=
|
||||
H;b.prototype.compileNode=function(a){return this.error("Expansion must be used inside a destructuring assignment or parameter list")};b.prototype.asReference=function(a){return this};b.prototype.eachName=function(a){};return b}(a);e.While=w=function(a){function b(a,b){this.condition=null!=b&&b.invert?a.invert():a;this.guard=null!=b?b.guard:void 0}na(b,a);b.prototype.children=["condition","guard","body"];b.prototype.isStatement=fa;b.prototype.makeReturn=function(a){if(a)return b.__super__.makeReturn.apply(this,
|
||||
arguments);this.returns=!this.jumps({loop:!0});return this};b.prototype.addBody=function(a){this.body=a;return this};b.prototype.jumps=function(){var a,b,f,d;a=this.body.expressions;if(!a.length)return!1;b=0;for(d=a.length;b<d;b++)if(f=a[b],f=f.jumps({loop:!0}))return f;return!1};b.prototype.compileNode=function(a){var b,f,d;a.indent+=da;d="";b=this.body;b.isEmpty()?b=this.makeCode(""):(this.returns&&(b.makeReturn(f=a.scope.freeVariable("results")),d=""+this.tab+f+" \x3d [];\n"),this.guard&&(1<b.expressions.length?
|
||||
b.expressions.unshift(new E((new D(this.guard)).invert(),new ua("continue"))):this.guard&&(b=c.wrap([new E(this.guard,b)]))),b=[].concat(this.makeCode("\n"),b.compileToFragments(a,u),this.makeCode("\n"+this.tab)));a=[].concat(this.makeCode(d+this.tab+"while ("),this.condition.compileToFragments(a,O),this.makeCode(") {"),b,this.makeCode("}"));this.returns&&a.push(this.makeCode("\n"+this.tab+"return "+f+";"));return a};return b}(a);e.Op=A=function(a){function b(a,b,e,n){if("in"===a)return new N(b,e);
|
||||
if("do"===a)return this.generateDo(b);if("new"===a){if(b instanceof g&&!b["do"]&&!b.isNew)return b.newInstance();if(b instanceof p&&b.bound||b["do"])b=new D(b)}this.operator=c[a]||a;this.first=b;this.second=e;this.flip=!!n;return this}var c,e;na(b,a);c={"\x3d\x3d":"\x3d\x3d\x3d","!\x3d":"!\x3d\x3d",of:"in",yieldfrom:"yield*"};e={"!\x3d\x3d":"\x3d\x3d\x3d","\x3d\x3d\x3d":"!\x3d\x3d"};b.prototype.children=["first","second"];b.prototype.isNumber=function(){var a;return this.isUnary()&&("+"===(a=this.operator)||
|
||||
"-"===a)&&this.first instanceof L&&this.first.isNumber()};b.prototype.isYield=function(){var a;return"yield"===(a=this.operator)||"yield*"===a};b.prototype.isUnary=function(){return!this.second};b.prototype.isComplex=function(){return!this.isNumber()};b.prototype.isChainable=function(){var a;return"\x3c"===(a=this.operator)||"\x3e"===a||"\x3e\x3d"===a||"\x3c\x3d"===a||"\x3d\x3d\x3d"===a||"!\x3d\x3d"===a};b.prototype.invert=function(){var a,d,c;if(this.isChainable()&&this.first.isChainable()){a=!0;
|
||||
for(d=this;d&&d.operator;)a&&(a=d.operator in e),d=d.first;if(!a)return(new D(this)).invert();for(d=this;d&&d.operator;)d.invert=!d.invert,d.operator=e[d.operator],d=d.first;return this}return(d=e[this.operator])?(this.operator=d,this.first.unwrap()instanceof b&&this.first.invert(),this):this.second?(new D(this)).invert():"!"===this.operator&&(a=this.first.unwrap())instanceof b&&("!"===(c=a.operator)||"in"===c||"instanceof"===c)?a:new b("!",this)};b.prototype.unfoldSoak=function(a){var b;return("++"===
|
||||
(b=this.operator)||"--"===b||"delete"===b)&&Ka(a,this,"first")};b.prototype.generateDo=function(a){var b,f,c,e,n;e=[];n=(a instanceof V&&(b=a.value.unwrap())instanceof p?b:a).params||[];b=0;for(f=n.length;b<f;b++)c=n[b],c.value?(e.push(c.value),delete c.value):e.push(c);a=new g(a,e);a["do"]=!0;return a};b.prototype.compileNode=function(a){var b,f;b=this.isChainable()&&this.first.isChainable();b||(this.first.front=this.front);"delete"===this.operator&&a.scope.check(this.first.unwrapAll().value)&&this.error("delete operand may not be argument or var");
|
||||
("--"===(f=this.operator)||"++"===f)&&(f=Ga(this.first.unwrapAll().value))&&this.first.error(f);if(this.isYield())return this.compileYield(a);if(this.isUnary())return this.compileUnary(a);if(b)return this.compileChain(a);switch(this.operator){case "?":return this.compileExistence(a);case "**":return this.compilePower(a);case "//":return this.compileFloorDivision(a);case "%%":return this.compileModulo(a);default:return b=this.first.compileToFragments(a,y),f=this.second.compileToFragments(a,y),b=[].concat(b,
|
||||
this.makeCode(" "+this.operator+" "),f),a.level<=y?b:this.wrapInBraces(b)}};b.prototype.compileChain=function(a){var b;b=this.first.second.cache(a);this.first.second=b[0];b=b[1];a=this.first.compileToFragments(a,y).concat(this.makeCode(" "+(this.invert?"\x26\x26":"||")+" "),b.compileToFragments(a),this.makeCode(" "+this.operator+" "),this.second.compileToFragments(a,y));return this.wrapInBraces(a)};b.prototype.compileExistence=function(a){var b,f;this.first.isComplex()?(f=new z(a.scope.freeVariable("ref")),
|
||||
b=new D(new V(f,this.first))):f=b=this.first;return(new E(new F(b),f,{type:"if"})).addElse(this.second).compileToFragments(a)};b.prototype.compileUnary=function(a){var d,f,c;f=[];d=this.operator;f.push([this.makeCode(d)]);if("!"===d&&this.first instanceof F)return this.first.negated=!this.first.negated,this.first.compileToFragments(a);if(a.level>=q)return(new D(this)).compileToFragments(a);c="+"===d||"-"===d;("new"===d||"typeof"===d||"delete"===d||c&&this.first instanceof b&&this.first.operator===
|
||||
d)&&f.push([this.makeCode(" ")]);if(c&&this.first instanceof b||"new"===d&&this.first.isStatement(a))this.first=new D(this.first);f.push(this.first.compileToFragments(a,y));this.flip&&f.reverse();return this.joinFragmentArrays(f,"")};b.prototype.compileYield=function(a){var b,f,c;f=[];b=this.operator;null==a.scope.parent&&this.error("yield can only occur inside functions");0<=Ha.call(Object.keys(this.first),"expression")&&!(this.first instanceof ia)?null!=this.first.expression&&f.push(this.first.expression.compileToFragments(a,
|
||||
y)):(a.level>=O&&f.push([this.makeCode("(")]),f.push([this.makeCode(b)]),""!==(null!=(c=this.first.base)?c.value:void 0)&&f.push([this.makeCode(" ")]),f.push(this.first.compileToFragments(a,y)),a.level>=O&&f.push([this.makeCode(")")]));return this.joinFragmentArrays(f,"")};b.prototype.compilePower=function(a){var b;b=new L(new z("Math"),[new va(new P("pow"))]);return(new g(b,[this.first,this.second])).compileToFragments(a)};b.prototype.compileFloorDivision=function(a){var d,f;f=new L(new z("Math"),
|
||||
[new va(new P("floor"))]);d=this.second.isComplex()?new D(this.second):this.second;d=new b("/",this.first,d);return(new g(f,[d])).compileToFragments(a)};b.prototype.compileModulo=function(a){var b;b=new L(new B(ya("modulo",a)));return(new g(b,[this.first,this.second])).compileToFragments(a)};b.prototype.toString=function(a){return b.__super__.toString.call(this,a,this.constructor.name+" "+this.operator)};return b}(a);e.In=N=function(a){function b(a,b){this.object=a;this.array=b}na(b,a);b.prototype.children=
|
||||
["object","array"];b.prototype.invert=S;b.prototype.compileNode=function(a){var b,f,d,c,e;if(this.array instanceof L&&this.array.isArray()&&this.array.base.objects.length){e=this.array.base.objects;f=0;for(d=e.length;f<d;f++)if(c=e[f],c instanceof Q){b=!0;break}if(!b)return this.compileOrTest(a)}return this.compileLoopTest(a)};b.prototype.compileOrTest=function(a){var b,f,d,c,e,g,n,h,m,k;b=this.object.cache(a,y);m=b[0];n=b[1];f=this.negated?[" !\x3d\x3d "," \x26\x26 "]:[" \x3d\x3d\x3d "," || "];b=
|
||||
f[0];f=f[1];k=[];h=this.array.base.objects;d=e=0;for(g=h.length;e<g;d=++e)c=h[d],d&&k.push(this.makeCode(f)),k=k.concat(d?n:m,this.makeCode(b),c.compileToFragments(a,q));return a.level<y?k:this.wrapInBraces(k)};b.prototype.compileLoopTest=function(a){var b,f,d;b=this.object.cache(a,h);d=b[0];f=b[1];b=[].concat(this.makeCode(ya("indexOf",a)+".call("),this.array.compileToFragments(a,h),this.makeCode(", "),f,this.makeCode(") "+(this.negated?"\x3c 0":"\x3e\x3d 0")));if(Ca(d)===Ca(f))return b;b=d.concat(this.makeCode(", "),
|
||||
b);return a.level<h?b:this.wrapInBraces(b)};b.prototype.toString=function(a){return b.__super__.toString.call(this,a,this.constructor.name+(this.negated?"!":""))};return b}(a);e.Try=function(a){function b(a,b,f,d){this.attempt=a;this.errorVariable=b;this.recovery=f;this.ensure=d}na(b,a);b.prototype.children=["attempt","recovery","ensure"];b.prototype.isStatement=fa;b.prototype.jumps=function(a){var b;return this.attempt.jumps(a)||(null!=(b=this.recovery)?b.jumps(a):void 0)};b.prototype.makeReturn=
|
||||
function(a){this.attempt&&(this.attempt=this.attempt.makeReturn(a));this.recovery&&(this.recovery=this.recovery.makeReturn(a));return this};b.prototype.compileNode=function(a){var b,f,d,c,e;a.indent+=da;e=this.attempt.compileToFragments(a,u);b=this.recovery?(f=a.scope.freeVariable("error",{reserve:!1}),c=new z(f),this.errorVariable?(d=Ga(this.errorVariable.unwrapAll().value),d?this.errorVariable.error(d):void 0,this.recovery.unshift(new V(this.errorVariable,c))):void 0,[].concat(this.makeCode(" catch ("),
|
||||
c.compileToFragments(a),this.makeCode(") {\n"),this.recovery.compileToFragments(a,u),this.makeCode("\n"+this.tab+"}"))):this.ensure||this.recovery?[]:(f=a.scope.freeVariable("error",{reserve:!1}),[this.makeCode(" catch ("+f+") {}")]);a=this.ensure?[].concat(this.makeCode(" finally {\n"),this.ensure.compileToFragments(a,u),this.makeCode("\n"+this.tab+"}")):[];return[].concat(this.makeCode(this.tab+"try {\n"),e,this.makeCode("\n"+this.tab+"}"),b,a)};return b}(a);e.Throw=ia=function(a){function b(a){this.expression=
|
||||
a}na(b,a);b.prototype.children=["expression"];b.prototype.isStatement=fa;b.prototype.jumps=H;b.prototype.makeReturn=ea;b.prototype.compileNode=function(a){return[].concat(this.makeCode(this.tab+"throw "),this.expression.compileToFragments(a),this.makeCode(";"))};return b}(a);e.Existence=F=function(a){function b(a){this.expression=a}na(b,a);b.prototype.children=["expression"];b.prototype.invert=S;b.prototype.compileNode=function(a){var b,f,d;this.expression.front=this.front;d=this.expression.compile(a,
|
||||
y);this.expression.unwrap()instanceof z&&!a.scope.check(d)?(f=this.negated?["\x3d\x3d\x3d","||"]:["!\x3d\x3d","\x26\x26"],b=f[0],f=f[1],d="typeof "+d+" "+b+' "undefined" '+f+" "+d+" "+b+" null"):d=d+" "+(this.negated?"\x3d\x3d":"!\x3d")+" null";return[this.makeCode(a.level<=r?d:"("+d+")")]};return b}(a);e.Parens=D=function(a){function b(a){this.body=a}na(b,a);b.prototype.children=["body"];b.prototype.unwrap=function(){return this.body};b.prototype.isComplex=function(){return this.body.isComplex()};
|
||||
b.prototype.compileNode=function(a){var b,f;b=this.body.unwrap();if(b instanceof L&&b.isAtomic())return b.front=this.front,b.compileToFragments(a);f=b.compileToFragments(a,O);return a.level<y&&(b instanceof A||b instanceof g||b instanceof I&&b.returns)?f:this.wrapInBraces(f)};return b}(a);e.StringWithInterpolations=Ua=function(a){function b(){return b.__super__.constructor.apply(this,arguments)}na(b,a);b.prototype.compileNode=function(a){var c,f,d,e,g;if(!a.inTaggedTemplateCall)return b.__super__.compileNode.apply(this,
|
||||
arguments);d=this.body.unwrap();f=[];d.traverseChildren(!1,function(a){if(a instanceof Za)f.push(a);else if(a instanceof D)return f.push(a),!1;return!0});d=[];d.push(this.makeCode("`"));e=0;for(g=f.length;e<g;e++)c=f[e],c instanceof Za?(c=c.value.slice(1,-1),c=c.replace(/(\\*)(`|\$\{)/g,function(a,b,d){return 0===b.length%2?b+"\\"+d:a}),d.push(this.makeCode(c))):(d.push(this.makeCode("${")),d.push.apply(d,c.compileToFragments(a,O)),d.push(this.makeCode("}")));d.push(this.makeCode("`"));return d};
|
||||
return b}(D);e.For=I=function(a){function b(a,b){this.source=b.source;this.guard=b.guard;this.step=b.step;this.name=b.name;this.index=b.index;this.body=c.wrap([a]);this.own=!!b.own;this.object=!!b.object;(this.from=!!b.from)&&this.index&&this.index.error("cannot use index with for-from");this.own&&!this.object&&b.ownTag.error("cannot use own with for-"+(this.from?"from":"in"));this.object&&(a=[this.index,this.name],this.name=a[0],this.index=a[1]);this.index instanceof L&&!this.index.isAssignable()&&
|
||||
this.index.error("index cannot be a pattern matching expression");this.range=this.source instanceof L&&this.source.base instanceof Y&&!this.source.properties.length&&!this.from;this.pattern=this.name instanceof L;this.range&&this.index&&this.index.error("indexes do not apply to range loops");this.range&&this.pattern&&this.name.error("cannot pattern match over range loops");this.returns=!1}na(b,a);b.prototype.children=["body","source","guard","step"];b.prototype.compileNode=function(a){var b,f,d,e,
|
||||
g,m,k,n,q,r,l,p,y,t,w,v,C,A,x,H,O;b=c.wrap([this.body]);q=b.expressions;q=q[q.length-1];(null!=q?q.jumps():void 0)instanceof U&&(this.returns=!1);w=this.range?this.source.base:this.source;d=a.scope;this.pattern||(n=this.name&&this.name.compile(a,h));q=this.index&&this.index.compile(a,h);n&&!this.pattern&&d.find(n);!q||this.index instanceof L||d.find(q);this.returns&&(k=d.freeVariable("results"));this.from?this.pattern&&(l=d.freeVariable("x",{single:!0})):l=this.object&&q||d.freeVariable("i",{single:!0});
|
||||
p=(this.range||this.from)&&n||q||l;y=p!==l?p+" \x3d ":"";this.step&&!this.range&&(q=this.cacheToCodeFragments(this.step.cache(a,h,ta)),g=q[0],x=q[1],this.step.isNumber()&&(A=Number(x)));this.pattern&&(n=l);m=q=O="";r=this.tab+da;this.range?e=w.compileToFragments(Fa(a,{index:l,name:n,step:this.step,isComplex:ta})):(H=this.source.compile(a,h),!n&&!this.own||this.source.unwrap()instanceof z||(m+=""+this.tab+(w=d.freeVariable("ref"))+" \x3d "+H+";\n",H=w),!n||this.pattern||this.from||(t=n+" \x3d "+H+
|
||||
"["+p+"]"),this.object||this.from||(g!==x&&(m+=""+this.tab+g+";\n"),n=0>A,this.step&&null!=A&&n||(f=d.freeVariable("len")),e=""+y+l+" \x3d 0, "+f+" \x3d "+H+".length",g=""+y+l+" \x3d "+H+".length - 1",f=l+" \x3c "+f,d=l+" \x3e\x3d 0",this.step?(null!=A?n&&(f=d,e=g):(f=x+" \x3e 0 ? "+f+" : "+d,e="("+x+" \x3e 0 ? ("+e+") : "+g+")"),l=l+" +\x3d "+x):l=""+(p!==l?"++"+l:l+"++"),e=[this.makeCode(e+"; "+f+"; "+y+l)]));this.returns&&(v=""+this.tab+k+" \x3d [];\n",C="\n"+this.tab+"return "+k+";",b.makeReturn(k));
|
||||
this.guard&&(1<b.expressions.length?b.expressions.unshift(new E((new D(this.guard)).invert(),new ua("continue"))):this.guard&&(b=c.wrap([new E(this.guard,b)])));this.pattern&&b.expressions.unshift(new V(this.name,this.from?new z(p):new B(H+"["+p+"]")));k=[].concat(this.makeCode(m),this.pluckDirectCall(a,b));t&&(O="\n"+r+t+";");this.object?(e=[this.makeCode(p+" in "+H)],this.own&&(q="\n"+r+"if (!"+ya("hasProp",a)+".call("+H+", "+p+")) continue;")):this.from&&(e=[this.makeCode(p+" of "+H)]);(a=b.compileToFragments(Fa(a,
|
||||
{indent:r}),u))&&0<a.length&&(a=[].concat(this.makeCode("\n"),a,this.makeCode("\n")));return[].concat(k,this.makeCode(""+(v||"")+this.tab+"for ("),e,this.makeCode(") {"+q+O),a,this.makeCode(this.tab+"}"+(C||"")))};b.prototype.pluckDirectCall=function(a,b){var c,d,e,h,n,m,k,q,r,l,y,t,w,v,B;d=[];r=b.expressions;n=m=0;for(k=r.length;m<k;n=++m)if(e=r[n],e=e.unwrapAll(),e instanceof g&&(B=null!=(l=e.variable)?l.unwrapAll():void 0,B instanceof p||B instanceof L&&(null!=(y=B.base)?y.unwrapAll():void 0)instanceof
|
||||
p&&1===B.properties.length&&("call"===(t=null!=(w=B.properties[0].name)?w.value:void 0)||"apply"===t)))h=(null!=(v=B.base)?v.unwrapAll():void 0)||B,q=new z(a.scope.freeVariable("fn")),c=new L(q),B.base&&(c=[c,B],B.base=c[0],c=c[1]),b.expressions[n]=new g(c,e.args),d=d.concat(this.makeCode(this.tab),(new V(q,h)).compileToFragments(a,u),this.makeCode(";\n"));return d};return b}(w);e.Switch=function(a){function b(a,b,c){this.subject=a;this.cases=b;this.otherwise=c}na(b,a);b.prototype.children=["subject",
|
||||
"cases","otherwise"];b.prototype.isStatement=fa;b.prototype.jumps=function(a){var b,c,d,e,g;null==a&&(a={block:!0});e=this.cases;c=0;for(d=e.length;c<d;c++)if(b=e[c],b=b[1],b=b.jumps(a))return b;return null!=(g=this.otherwise)?g.jumps(a):void 0};b.prototype.makeReturn=function(a){var b,f,d,e,g;e=this.cases;b=0;for(f=e.length;b<f;b++)d=e[b],d[1].makeReturn(a);a&&(this.otherwise||(this.otherwise=new c([new B("void 0")])));null!=(g=this.otherwise)&&g.makeReturn(a);return this};b.prototype.compileNode=
|
||||
function(a){var b,c,d,e,g,h,m,k,n,q,r,l,p;m=a.indent+da;k=a.indent=m+da;h=[].concat(this.makeCode(this.tab+"switch ("),this.subject?this.subject.compileToFragments(a,O):this.makeCode("false"),this.makeCode(") {\n"));l=this.cases;g=n=0;for(q=l.length;n<q;g=++n){b=l[g];e=b[0];b=b[1];p=ma([e]);e=0;for(r=p.length;e<r;e++)d=p[e],this.subject||(d=d.invert()),h=h.concat(this.makeCode(m+"case "),d.compileToFragments(a,O),this.makeCode(":\n"));0<(c=b.compileToFragments(a,u)).length&&(h=h.concat(c,this.makeCode("\n")));
|
||||
if(g===this.cases.length-1&&!this.otherwise)break;g=this.lastNonComment(b.expressions);g instanceof U||g instanceof B&&g.jumps()&&"debugger"!==g.value||h.push(d.makeCode(k+"break;\n"))}this.otherwise&&this.otherwise.expressions.length&&h.push.apply(h,[this.makeCode(m+"default:\n")].concat(Aa.call(this.otherwise.compileToFragments(a,u)),[this.makeCode("\n")]));h.push(this.makeCode(this.tab+"}"));return h};return b}(a);e.If=E=function(a){function b(a,b,c){this.body=b;null==c&&(c={});this.condition=
|
||||
"unless"===c.type?a.invert():a;this.elseBody=null;this.isChain=!1;this.soak=c.soak}na(b,a);b.prototype.children=["condition","body","elseBody"];b.prototype.bodyNode=function(){var a;return null!=(a=this.body)?a.unwrap():void 0};b.prototype.elseBodyNode=function(){var a;return null!=(a=this.elseBody)?a.unwrap():void 0};b.prototype.addElse=function(a){this.isChain?this.elseBodyNode().addElse(a):(this.isChain=a instanceof b,this.elseBody=this.ensureBlock(a),this.elseBody.updateLocationDataIfMissing(a.locationData));
|
||||
return this};b.prototype.isStatement=function(a){var b;return(null!=a?a.level:void 0)===u||this.bodyNode().isStatement(a)||(null!=(b=this.elseBodyNode())?b.isStatement(a):void 0)};b.prototype.jumps=function(a){var b;return this.body.jumps(a)||(null!=(b=this.elseBody)?b.jumps(a):void 0)};b.prototype.compileNode=function(a){return this.isStatement(a)?this.compileStatement(a):this.compileExpression(a)};b.prototype.makeReturn=function(a){a&&(this.elseBody||(this.elseBody=new c([new B("void 0")])));this.body&&
|
||||
(this.body=new c([this.body.makeReturn(a)]));this.elseBody&&(this.elseBody=new c([this.elseBody.makeReturn(a)]));return this};b.prototype.ensureBlock=function(a){return a instanceof c?a:new c([a])};b.prototype.compileStatement=function(a){var c,f,d,e;c=X(a,"chainChild");if(X(a,"isExistentialEquals"))return(new b(this.condition.invert(),this.elseBodyNode(),{type:"if"})).compileToFragments(a);e=a.indent+da;d=this.condition.compileToFragments(a,O);f=this.ensureBlock(this.body).compileToFragments(Fa(a,
|
||||
{indent:e}));f=[].concat(this.makeCode("if ("),d,this.makeCode(") {\n"),f,this.makeCode("\n"+this.tab+"}"));c||f.unshift(this.makeCode(this.tab));if(!this.elseBody)return f;c=f.concat(this.makeCode(" else "));this.isChain?(a.chainChild=!0,c=c.concat(this.elseBody.unwrap().compileToFragments(a,u))):c=c.concat(this.makeCode("{\n"),this.elseBody.compileToFragments(Fa(a,{indent:e}),u),this.makeCode("\n"+this.tab+"}"));return c};b.prototype.compileExpression=function(a){var b,c,d;d=this.condition.compileToFragments(a,
|
||||
r);c=this.bodyNode().compileToFragments(a,h);b=this.elseBodyNode()?this.elseBodyNode().compileToFragments(a,h):[this.makeCode("void 0")];b=d.concat(this.makeCode(" ? "),c,this.makeCode(" : "),b);return a.level>=r?this.wrapInBraces(b):b};b.prototype.unfoldSoak=function(){return this.soak&&this};return b}(a);ka={extend:function(a){return"function(child, parent) { for (var key in parent) { if ("+ya("hasProp",a)+".call(parent, key)) child[key] \x3d parent[key]; } function ctor() { this.constructor \x3d child; } ctor.prototype \x3d parent.prototype; child.prototype \x3d new ctor(); child.__super__ \x3d parent.prototype; return child; }"},
|
||||
bind:function(){return"function(fn, me){ return function(){ return fn.apply(me, arguments); }; }"},indexOf:function(){return"[].indexOf || function(item) { for (var i \x3d 0, l \x3d this.length; i \x3c l; i++) { if (i in this \x26\x26 this[i] \x3d\x3d\x3d item) return i; } return -1; }"},modulo:function(){return"function(a, b) { return (+a % (b \x3d +b) + b) % b; }"},hasProp:function(){return"{}.hasOwnProperty"},slice:function(){return"[].slice"}};u=1;O=2;h=3;r=4;y=5;q=6;da=" ";aa=/^[+-]?\d+$/;ya=
|
||||
function(a,b){var c,e;e=b.scope.root;if(a in e.utilities)return e.utilities[a];c=e.freeVariable(a);e.assign(c,ka[a](b));return e.utilities[a]=c};Na=function(a,b){a=a.replace(/\n/g,"$\x26"+b);return a.replace(/\s+$/,"")};gb=function(a){return a instanceof z&&"arguments"===a.value};Ra=function(a){return a instanceof ha||a instanceof p&&a.bound||a instanceof ja};ta=function(a){return a.isComplex()||("function"===typeof a.isAssignable?a.isAssignable():void 0)};Ka=function(a,b,c){if(a=b[c].unfoldSoak(a))return b[c]=
|
||||
a.body,a.body=new L(b),a}}).call(this);return e}();t["./sourcemap"]=function(){var e={};(function(){var t;t=function(){function e(e){this.line=e;this.columns=[]}e.prototype.add=function(e,a,c){var t;t=a[0];a=a[1];null==c&&(c={});if(!this.columns[e]||!c.noReplace)return this.columns[e]={line:this.line,column:e,sourceLine:t,sourceColumn:a}};e.prototype.sourceLocation=function(e){for(var a;!((a=this.columns[e])||0>=e);)e--;return a&&[a.sourceLine,a.sourceColumn]};return e}();e=function(){function e(){this.lines=
|
||||
[]}e.prototype.add=function(e,a,c){var V,g;null==c&&(c={});g=a[0];a=a[1];return((V=this.lines)[g]||(V[g]=new t(g))).add(a,e,c)};e.prototype.sourceLocation=function(e){var a,c;a=e[0];for(e=e[1];!((c=this.lines[a])||0>=a);)a--;return c&&c.sourceLocation(e)};e.prototype.generate=function(e,a){var c,t,g,v,p,l,G,F,x,w,K,M,I;null==e&&(e={});null==a&&(a=null);p=l=v=I=0;w=!1;c="";K=this.lines;g=t=0;for(G=K.length;t<G;g=++t)if(g=K[g])for(M=g.columns,g=0,F=M.length;g<F;g++)if(x=M[g]){for(;I<x.line;)v=0,w=!1,
|
||||
c+=";",I++;w&&(c+=",");c+=this.encodeVlq(x.column-v);v=x.column;c+=this.encodeVlq(0);c+=this.encodeVlq(x.sourceLine-l);l=x.sourceLine;c+=this.encodeVlq(x.sourceColumn-p);p=x.sourceColumn;w=!0}c={version:3,file:e.generatedFile||"",sourceRoot:e.sourceRoot||"",sources:e.sourceFiles||[""],names:[],mappings:c};e.inlineMap&&(c.sourcesContent=[a]);return c};e.prototype.encodeVlq=function(e){var a,c;a="";for(c=(Math.abs(e)<<1)+(0>e?1:0);c||!a;)e=c&31,(c>>=5)&&(e|=32),a+=this.encodeBase64(e);return a};e.prototype.encodeBase64=
|
||||
function(e){var a;if(!(a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"[e]))throw Error("Cannot Base64 encode value: "+e);return a};return e}()}).call(this);return e}();t["./coffee-script"]=function(){var e={};(function(){var pa,ua,V,a,c,Da,g,v,p,l,G,F,x,w,K,M,I,z,E,N={}.hasOwnProperty;v=t("fs");E=t("vm");K=t("path");pa=t("./lexer").Lexer;w=t("./parser").parser;l=t("./helpers");ua=t("./sourcemap");c=t("../../package.json");e.VERSION=c.version;e.FILE_EXTENSIONS=[".coffee",".litcoffee",
|
||||
".coffee.md"];e.helpers=l;V=function(a){switch(!1){case "function"!==typeof Buffer:return(new Buffer(a)).toString("base64");case "function"!==typeof btoa:return btoa(encodeURIComponent(a).replace(/%([0-9A-F]{2})/g,function(a,c){return String.fromCharCode("0x"+c)}));default:throw Error("Unable to base64 encode inline sourcemap.");}};c=function(a){return function(c,e){null==e&&(e={});try{return a.call(this,c,e)}catch(r){if("string"!==typeof c)throw r;throw l.updateSyntaxError(r,c,e.filename);}}};z=
|
||||
{};I={};e.compile=a=c(function(a,c){var e,g,h,k,m,p,t,v,E,H,F,G,C;h=l.extend;c=h({},c);p=c.sourceMap||c.inlineMap||null==c.filename;h=c.filename||"\x3canonymous\x3e";z[h]=a;p&&(H=new ua);g=x.tokenize(a,c);k=c;E=[];m=0;for(t=g.length;m<t;m++)e=g[m],"IDENTIFIER"===e[0]&&E.push(e[1]);k.referencedVars=E;if(null==c.bare||!0!==c.bare)for(k=0,m=g.length;k<m;k++)if(e=g[k],"IMPORT"===(v=e[0])||"EXPORT"===v){c.bare=!0;break}m=w.parse(g).compileToFragments(c);g=0;c.header&&(g+=1);c.shiftLine&&(g+=1);e=0;v="";
|
||||
t=0;for(E=m.length;t<E;t++)k=m[t],p&&(k.locationData&&!/^[;\s]*$/.test(k.code)&&H.add([k.locationData.first_line,k.locationData.first_column],[g,e],{noReplace:!0}),F=l.count(k.code,"\n"),g+=F,e=F?k.code.length-(k.code.lastIndexOf("\n")+1):e+k.code.length),v+=k.code;c.header&&(e="Generated by CoffeeScript "+this.VERSION,v="// "+e+"\n"+v);p&&(C=H.generate(c,a),I[h]=H);c.inlineMap&&(a=V(JSON.stringify(C)),h="//# sourceURL\x3d"+(null!=(G=c.filename)?G:"coffeescript"),v=v+"\n"+("//# sourceMappingURL\x3ddata:application/json;base64,"+
|
||||
a)+"\n"+h);return c.sourceMap?{js:v,sourceMap:H,v3SourceMap:JSON.stringify(C,null,2)}:v});e.tokens=c(function(a,c){return x.tokenize(a,c)});e.nodes=c(function(a,c){return"string"===typeof a?w.parse(x.tokenize(a,c)):w.parse(a)});e.run=function(c,e){var g,k,h;null==e&&(e={});k=t.main;k.filename=process.argv[1]=e.filename?v.realpathSync(e.filename):"\x3canonymous\x3e";k.moduleCache&&(k.moduleCache={});g=null!=e.filename?K.dirname(v.realpathSync(e.filename)):v.realpathSync(".");k.paths=t("module")._nodeModulePaths(g);
|
||||
if(!l.isCoffee(k.filename)||t.extensions)c=a(c,e),c=null!=(h=c.js)?h:c;return k._compile(c,k.filename)};e.eval=function(c,e){var g,k,h,m,l,p,w,v,z,x;null==e&&(e={});if(c=c.trim()){m=null!=(l=E.Script.createContext)?l:E.createContext;l=null!=(h=E.isContext)?h:function(a){return e.sandbox instanceof m().constructor};if(m){if(null!=e.sandbox){if(l(e.sandbox))x=e.sandbox;else for(p in x=m(),l=e.sandbox,l)N.call(l,p)&&(h=l[p],x[p]=h);x.global=x.root=x.GLOBAL=x}else x=global;x.__filename=e.filename||"eval";
|
||||
x.__dirname=K.dirname(x.__filename);if(x===global&&!x.module&&!x.require){g=t("module");x.module=k=new g(e.modulename||"eval");x.require=h=function(a){return g._load(a,k,!0)};k.filename=x.__filename;z=Object.getOwnPropertyNames(t);l=0;for(w=z.length;l<w;l++)v=z[l],"paths"!==v&&"arguments"!==v&&"caller"!==v&&(h[v]=t[v]);h.paths=k.paths=g._nodeModulePaths(process.cwd());h.resolve=function(a){return g._resolveFilename(a,k)}}}l={};for(p in e)N.call(e,p)&&(h=e[p],l[p]=h);l.bare=!0;c=a(c,l);return x===
|
||||
global?E.runInThisContext(c):E.runInContext(c,x)}};e.register=function(){return t("./register")};if(t.extensions)for(M=this.FILE_EXTENSIONS,Da=function(a){var c;return null!=(c=t.extensions)[a]?c[a]:c[a]=function(){throw Error("Use CoffeeScript.register() or require the coffee-script/register module to require "+a+" files.");}},G=0,F=M.length;G<F;G++)c=M[G],Da(c);e._compileFile=function(c,e,g){var k,h;null==e&&(e=!1);null==g&&(g=!1);h=v.readFileSync(c,"utf8");h=65279===h.charCodeAt(0)?h.substring(1):
|
||||
h;try{k=a(h,{filename:c,sourceMap:e,inlineMap:g,sourceFiles:[c],literate:l.isLiterate(c)})}catch(y){throw l.updateSyntaxError(y,h,c);}return k};x=new pa;w.lexer={lex:function(){var a,c;(c=w.tokens[this.pos++])?(a=c[0],this.yytext=c[1],this.yylloc=c[2],w.errorToken=c.origin||c,this.yylineno=this.yylloc.first_line):a="";return a},setInput:function(a){w.tokens=a;return this.pos=0},upcomingInput:function(){return""}};w.yy=t("./nodes");w.yy.parseError=function(a,c){var e,g,h,k;h=w.errorToken;k=w.tokens;
|
||||
e=h[0];g=h[1];a=h[2];g=function(){switch(!1){case h!==k[k.length-1]:return"end of input";case "INDENT"!==e&&"OUTDENT"!==e:return"indentation";case "IDENTIFIER"!==e&&"NUMBER"!==e&&"INFINITY"!==e&&"STRING"!==e&&"STRING_START"!==e&&"REGEX"!==e&&"REGEX_START"!==e:return e.replace(/_START$/,"").toLowerCase();default:return l.nameWhitespaceCharacter(g)}}();return l.throwSyntaxError("unexpected "+g,a)};g=function(a,c){var e,g,h,k;a.isNative()?e="native":(a.isEval()?(g=a.getScriptNameOrSourceURL())||a.getEvalOrigin():
|
||||
g=a.getFileName(),g||(g="\x3canonymous\x3e"),h=a.getLineNumber(),e=a.getColumnNumber(),e=(c=c(g,h,e))?g+":"+c[0]+":"+c[1]:g+":"+h+":"+e);g=a.getFunctionName();h=a.isConstructor();if(a.isToplevel()||h)return h?"new "+(g||"\x3canonymous\x3e")+" ("+e+")":g?g+" ("+e+")":e;h=a.getMethodName();k=a.getTypeName();return g?(c=a="",k&&g.indexOf(k)&&(c=k+"."),h&&g.indexOf("."+h)!==g.length-h.length-1&&(a=" [as "+h+"]"),""+c+g+a+" ("+e+")"):k+"."+(h||"\x3canonymous\x3e")+" ("+e+")"};p=function(c){return null!=
|
||||
I[c]?I[c]:null!=I["\x3canonymous\x3e"]?I["\x3canonymous\x3e"]:null!=z[c]?(c=a(z[c],{filename:c,sourceMap:!0,literate:l.isLiterate(c)}),c.sourceMap):null};Error.prepareStackTrace=function(a,c){var k,m,h;h=function(a,c,e){var g;a=p(a);null!=a&&(g=a.sourceLocation([c-1,e-1]));return null!=g?[g[0]+1,g[1]+1]:null};m=function(){var a,m,l;l=[];a=0;for(m=c.length;a<m;a++){k=c[a];if(k.getFunction()===e.run)break;l.push(" at "+g(k,h))}return l}();return a.toString()+"\n"+m.join("\n")+"\n"}}).call(this);
|
||||
return e}();t["./browser"]=function(){(function(){var e,pa,ua,V=[].indexOf||function(a){for(var c=0,e=this.length;c<e;c++)if(c in this&&this[c]===a)return c;return-1};e=t("./coffee-script");e.require=t;pa=e.compile;e.eval=function(a,c){null==c&&(c={});null==c.bare&&(c.bare=!0);return eval(pa(a,c))};e.run=function(a,c){null==c&&(c={});c.bare=!0;c.shiftLine=!0;return Function(pa(a,c))()};"undefined"!==typeof window&&null!==window&&("undefined"!==typeof btoa&&null!==btoa&&"undefined"!==typeof JSON&&
|
||||
null!==JSON&&(pa=function(a,c){null==c&&(c={});c.inlineMap=!0;return e.compile(a,c)}),e.load=function(a,c,t,g){var v;null==t&&(t={});null==g&&(g=!1);t.sourceFiles=[a];v=window.ActiveXObject?new window.ActiveXObject("Microsoft.XMLHTTP"):new window.XMLHttpRequest;v.open("GET",a,!0);"overrideMimeType"in v&&v.overrideMimeType("text/plain");v.onreadystatechange=function(){var p;if(4===v.readyState){if(0===(p=v.status)||200===p)p=[v.responseText,t],g||e.run.apply(e,p);else throw Error("Could not load "+
|
||||
a);if(c)return c(p)}};return v.send(null)},ua=function(){var a,c,t,g,v,p,l,G,F,x,w;w=window.document.getElementsByTagName("script");c=["text/coffeescript","text/literate-coffeescript"];a=function(){var a,e,g,l;l=[];a=0;for(e=w.length;a<e;a++)F=w[a],(g=F.type,0<=V.call(c,g))&&l.push(F);return l}();p=0;t=function(){var c;c=a[p];if(c instanceof Array)return e.run.apply(e,c),p++,t()};g=function(g,l){var p,v;p={literate:g.type===c[1]};if(v=g.src||g.getAttribute("data-src"))return e.load(v,function(c){a[l]=
|
||||
c;return t()},p,!0);p.sourceFiles=["embedded"];return a[l]=[g.innerHTML,p]};v=l=0;for(G=a.length;l<G;v=++l)x=a[v],g(x,v);return t()},window.addEventListener?window.addEventListener("DOMContentLoaded",ua,!1):window.attachEvent("onload",ua))}).call(this);return{}}();return t["./coffee-script"]}();"function"===typeof define&&define.amd?define(function(){return ua}):t.CoffeeScript=ua})(this);
|
||||
3202
docs/v1/index.html
Normal file
11488
docs/v1/test.html
Normal file
319
docs/v2/annotated-source/browser.html
Normal file
@@ -0,0 +1,319 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>browser.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>browser.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>This <strong>Browser</strong> compatibility layer extends core CoffeeScript functions
|
||||
to make things work smoothly when compiling code directly in the browser.
|
||||
We add support for loading remote Coffee scripts via <strong>XHR</strong>, and
|
||||
<code>text/coffeescript</code> script tags, source maps via data-URLs, and so on.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>
|
||||
CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffeescript'</span>
|
||||
CoffeeScript.<span class="hljs-built_in">require</span> = <span class="hljs-built_in">require</span>
|
||||
compile = CoffeeScript.compile</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Use standard JavaScript <code>eval</code> to eval code.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript.eval = <span class="hljs-function"><span class="hljs-params">(code, options = {})</span> -></span>
|
||||
options.bare ?= <span class="hljs-literal">on</span>
|
||||
eval compile code, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Running code does not provide access to this scope.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript.run = <span class="hljs-function"><span class="hljs-params">(code, options = {})</span> -></span>
|
||||
options.bare = <span class="hljs-literal">on</span>
|
||||
options.shiftLine = <span class="hljs-literal">on</span>
|
||||
Function(compile code, options)()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>If we’re not in a browser environment, we’re finished with the public API.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> <span class="hljs-built_in">window</span>?</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Include source maps where possible. If we’ve got a base64 encoder, a
|
||||
JSON serializer, and tools for escaping unicode characters, we’re good to go.
|
||||
Ported from <a href="https://developer.mozilla.org/en-US/docs/DOM/window.btoa">https://developer.mozilla.org/en-US/docs/DOM/window.btoa</a></p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> btoa? <span class="hljs-keyword">and</span> JSON?
|
||||
<span class="hljs-function"> <span class="hljs-title">compile</span> = <span class="hljs-params">(code, options = {})</span> -></span>
|
||||
options.inlineMap = <span class="hljs-literal">true</span>
|
||||
CoffeeScript.compile code, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Load a remote script from the current domain via XHR.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript.load = <span class="hljs-function"><span class="hljs-params">(url, callback, options = {}, hold = <span class="hljs-literal">false</span>)</span> -></span>
|
||||
options.sourceFiles = [url]
|
||||
xhr = <span class="hljs-keyword">if</span> <span class="hljs-built_in">window</span>.ActiveXObject
|
||||
<span class="hljs-keyword">new</span> <span class="hljs-built_in">window</span>.ActiveXObject(<span class="hljs-string">'Microsoft.XMLHTTP'</span>)
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-keyword">new</span> <span class="hljs-built_in">window</span>.XMLHttpRequest()
|
||||
xhr.open <span class="hljs-string">'GET'</span>, url, <span class="hljs-literal">true</span>
|
||||
xhr.overrideMimeType <span class="hljs-string">'text/plain'</span> <span class="hljs-keyword">if</span> <span class="hljs-string">'overrideMimeType'</span> <span class="hljs-keyword">of</span> xhr
|
||||
xhr.onreadystatechange = <span class="hljs-function">-></span>
|
||||
<span class="hljs-keyword">if</span> xhr.readyState <span class="hljs-keyword">is</span> <span class="hljs-number">4</span>
|
||||
<span class="hljs-keyword">if</span> xhr.status <span class="hljs-keyword">in</span> [<span class="hljs-number">0</span>, <span class="hljs-number">200</span>]
|
||||
param = [xhr.responseText, options]
|
||||
CoffeeScript.run param... <span class="hljs-keyword">unless</span> hold
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"Could not load <span class="hljs-subst">#{url}</span>"</span>
|
||||
callback param <span class="hljs-keyword">if</span> callback
|
||||
xhr.send <span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Activate CoffeeScript in the browser by having it compile and evaluate
|
||||
all script tags with a content-type of <code>text/coffeescript</code>.
|
||||
This happens on page load.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">runScripts</span> = -></span>
|
||||
scripts = <span class="hljs-built_in">window</span>.<span class="hljs-built_in">document</span>.getElementsByTagName <span class="hljs-string">'script'</span>
|
||||
coffeetypes = [<span class="hljs-string">'text/coffeescript'</span>, <span class="hljs-string">'text/literate-coffeescript'</span>]
|
||||
coffees = (s <span class="hljs-keyword">for</span> s <span class="hljs-keyword">in</span> scripts <span class="hljs-keyword">when</span> s.type <span class="hljs-keyword">in</span> coffeetypes)
|
||||
index = <span class="hljs-number">0</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">execute</span> = -></span>
|
||||
param = coffees[index]
|
||||
<span class="hljs-keyword">if</span> param <span class="hljs-keyword">instanceof</span> Array
|
||||
CoffeeScript.run param...
|
||||
index++
|
||||
execute()
|
||||
|
||||
<span class="hljs-keyword">for</span> script, i <span class="hljs-keyword">in</span> coffees
|
||||
<span class="hljs-keyword">do</span> (script, i) ->
|
||||
options = literate: script.type <span class="hljs-keyword">is</span> coffeetypes[<span class="hljs-number">1</span>]
|
||||
source = script.src <span class="hljs-keyword">or</span> script.getAttribute(<span class="hljs-string">'data-src'</span>)
|
||||
<span class="hljs-keyword">if</span> source
|
||||
options.filename = source
|
||||
CoffeeScript.load source,
|
||||
<span class="hljs-function"><span class="hljs-params">(param)</span> -></span>
|
||||
coffees[i] = param
|
||||
execute()
|
||||
options
|
||||
<span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">else</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p><code>options.filename</code> defines the filename the source map appears as
|
||||
in Developer Tools. If a script tag has an <code>id</code>, use that as the
|
||||
filename; otherwise use <code>coffeescript</code>, or <code>coffeescript1</code> etc.,
|
||||
leaving the first one unnumbered for the common case that there’s
|
||||
only one CoffeeScript script block to parse.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> options.filename = <span class="hljs-keyword">if</span> script.id <span class="hljs-keyword">and</span> script.id <span class="hljs-keyword">isnt</span> <span class="hljs-string">''</span> <span class="hljs-keyword">then</span> script.id <span class="hljs-keyword">else</span> <span class="hljs-string">"coffeescript<span class="hljs-subst">#{<span class="hljs-keyword">if</span> i <span class="hljs-keyword">isnt</span> <span class="hljs-number">0</span> <span class="hljs-keyword">then</span> i <span class="hljs-keyword">else</span> <span class="hljs-string">''</span>}</span>"</span>
|
||||
options.sourceFiles = [<span class="hljs-string">'embedded'</span>]
|
||||
coffees[i] = [script.innerHTML, options]
|
||||
|
||||
execute()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Listen for window load, both in decent browsers and in IE.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> <span class="hljs-built_in">window</span>.addEventListener
|
||||
<span class="hljs-built_in">window</span>.addEventListener <span class="hljs-string">'DOMContentLoaded'</span>, runScripts, <span class="hljs-literal">no</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-built_in">window</span>.attachEvent <span class="hljs-string">'onload'</span>, runScripts</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
345
docs/v2/annotated-source/cake.html
Normal file
@@ -0,0 +1,345 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>cake.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>cake.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p><code>cake</code> is a simplified version of <a href="http://www.gnu.org/software/make/">Make</a>
|
||||
(<a href="http://rake.rubyforge.org/">Rake</a>, <a href="http://github.com/280north/jake">Jake</a>)
|
||||
for CoffeeScript. You define tasks with names and descriptions in a Cakefile,
|
||||
and can call them from the command line, or invoke them from other tasks.</p>
|
||||
<p>Running <code>cake</code> with no arguments will print out a list of all the tasks in the
|
||||
current directory’s Cakefile.</p>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>External dependencies.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>fs = <span class="hljs-built_in">require</span> <span class="hljs-string">'fs'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span>
|
||||
helpers = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
optparse = <span class="hljs-built_in">require</span> <span class="hljs-string">'./optparse'</span>
|
||||
CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffeescript'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Register .coffee extension</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript.register()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Keep track of the list of defined tasks, the accepted options, and so on.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>tasks = {}
|
||||
options = {}
|
||||
switches = []
|
||||
oparse = <span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Mixin the top-level Cake functions for Cakefiles to use directly.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>helpers.extend <span class="hljs-built_in">global</span>,</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Define a Cake task with a short name, an optional sentence description,
|
||||
and the function to run as the action itself.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> task: <span class="hljs-function"><span class="hljs-params">(name, description, action)</span> -></span>
|
||||
[action, description] = [description, action] <span class="hljs-keyword">unless</span> action
|
||||
tasks[name] = {name, description, action}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Define an option that the Cakefile accepts. The parsed options hash,
|
||||
containing all of the command-line options passed, will be made available
|
||||
as the first argument to the action.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> option: <span class="hljs-function"><span class="hljs-params">(letter, flag, description)</span> -></span>
|
||||
switches.push [letter, flag, description]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Invoke another task in the current Cakefile.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> invoke: <span class="hljs-function"><span class="hljs-params">(name)</span> -></span>
|
||||
missingTask name <span class="hljs-keyword">unless</span> tasks[name]
|
||||
tasks[name].action options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Run <code>cake</code>. Executes all of the tasks you pass, in order. Note that Node’s
|
||||
asynchrony may cause tasks to execute in a different order than you’d expect.
|
||||
If no tasks are passed, print the help screen. Keep a reference to the
|
||||
original directory name, when running Cake tasks from subdirectories.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.run = <span class="hljs-function">-></span>
|
||||
<span class="hljs-built_in">global</span>.__originalDirname = fs.realpathSync <span class="hljs-string">'.'</span>
|
||||
process.chdir cakefileDirectory __originalDirname
|
||||
args = process.argv[<span class="hljs-number">2.</span>.]
|
||||
CoffeeScript.run fs.readFileSync(<span class="hljs-string">'Cakefile'</span>).toString(), filename: <span class="hljs-string">'Cakefile'</span>
|
||||
oparse = <span class="hljs-keyword">new</span> optparse.OptionParser switches
|
||||
<span class="hljs-keyword">return</span> printTasks() <span class="hljs-keyword">unless</span> args.length
|
||||
<span class="hljs-keyword">try</span>
|
||||
options = oparse.parse(args)
|
||||
<span class="hljs-keyword">catch</span> e
|
||||
<span class="hljs-keyword">return</span> fatalError <span class="hljs-string">"<span class="hljs-subst">#{e}</span>"</span>
|
||||
invoke arg <span class="hljs-keyword">for</span> arg <span class="hljs-keyword">in</span> options.arguments</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Display the list of Cake tasks in a format similar to <code>rake -T</code></p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">printTasks</span> = -></span>
|
||||
relative = path.relative <span class="hljs-keyword">or</span> path.resolve
|
||||
cakefilePath = path.join relative(__originalDirname, process.cwd()), <span class="hljs-string">'Cakefile'</span>
|
||||
<span class="hljs-built_in">console</span>.log <span class="hljs-string">"<span class="hljs-subst">#{cakefilePath}</span> defines the following tasks:\n"</span>
|
||||
<span class="hljs-keyword">for</span> name, task <span class="hljs-keyword">of</span> tasks
|
||||
spaces = <span class="hljs-number">20</span> - name.length
|
||||
spaces = <span class="hljs-keyword">if</span> spaces > <span class="hljs-number">0</span> <span class="hljs-keyword">then</span> Array(spaces + <span class="hljs-number">1</span>).join(<span class="hljs-string">' '</span>) <span class="hljs-keyword">else</span> <span class="hljs-string">''</span>
|
||||
desc = <span class="hljs-keyword">if</span> task.description <span class="hljs-keyword">then</span> <span class="hljs-string">"# <span class="hljs-subst">#{task.description}</span>"</span> <span class="hljs-keyword">else</span> <span class="hljs-string">''</span>
|
||||
<span class="hljs-built_in">console</span>.log <span class="hljs-string">"cake <span class="hljs-subst">#{name}</span><span class="hljs-subst">#{spaces}</span> <span class="hljs-subst">#{desc}</span>"</span>
|
||||
<span class="hljs-built_in">console</span>.log oparse.help() <span class="hljs-keyword">if</span> switches.length</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Print an error and exit when attempting to use an invalid task/option.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">fatalError</span> = <span class="hljs-params">(message)</span> -></span>
|
||||
<span class="hljs-built_in">console</span>.error message + <span class="hljs-string">'\n'</span>
|
||||
<span class="hljs-built_in">console</span>.log <span class="hljs-string">'To see a list of all tasks/options, run "cake"'</span>
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">missingTask</span> = <span class="hljs-params">(task)</span> -></span> fatalError <span class="hljs-string">"No such task: <span class="hljs-subst">#{task}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>When <code>cake</code> is invoked, search in the current and all parent directories
|
||||
to find the relevant Cakefile.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">cakefileDirectory</span> = <span class="hljs-params">(dir)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> dir <span class="hljs-keyword">if</span> fs.existsSync path.join dir, <span class="hljs-string">'Cakefile'</span>
|
||||
parent = path.normalize path.join dir, <span class="hljs-string">'..'</span>
|
||||
<span class="hljs-keyword">return</span> cakefileDirectory parent <span class="hljs-keyword">unless</span> parent <span class="hljs-keyword">is</span> dir
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"Cakefile not found in <span class="hljs-subst">#{process.cwd()}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
982
docs/v2/annotated-source/coffeescript.html
Normal file
@@ -0,0 +1,982 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>coffeescript.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>coffeescript.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>CoffeeScript can be used both on the server, as a command-line compiler based
|
||||
on Node.js/V8, or to run CoffeeScript directly in the browser. This module
|
||||
contains the main entry functions for tokenizing, parsing, and compiling
|
||||
source CoffeeScript into JavaScript.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>
|
||||
fs = <span class="hljs-built_in">require</span> <span class="hljs-string">'fs'</span>
|
||||
vm = <span class="hljs-built_in">require</span> <span class="hljs-string">'vm'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span>
|
||||
{Lexer} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./lexer'</span>
|
||||
{parser} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./parser'</span>
|
||||
helpers = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
SourceMap = <span class="hljs-built_in">require</span> <span class="hljs-string">'./sourcemap'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Require <code>package.json</code>, which is two levels above this file, as this file is
|
||||
evaluated from <code>lib/coffeescript</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>packageJson = <span class="hljs-built_in">require</span> <span class="hljs-string">'../../package.json'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>The current CoffeeScript version number.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.VERSION = packageJson.version
|
||||
|
||||
exports.FILE_EXTENSIONS = [<span class="hljs-string">'.coffee'</span>, <span class="hljs-string">'.litcoffee'</span>, <span class="hljs-string">'.coffee.md'</span>]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Expose helpers for testing.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.helpers = helpers</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Function that allows for btoa in both nodejs and the browser.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">base64encode</span> = <span class="hljs-params">(src)</span> -></span> <span class="hljs-keyword">switch</span>
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-keyword">typeof</span> Buffer <span class="hljs-keyword">is</span> <span class="hljs-string">'function'</span>
|
||||
Buffer.<span class="hljs-keyword">from</span>(src).toString(<span class="hljs-string">'base64'</span>)
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-keyword">typeof</span> btoa <span class="hljs-keyword">is</span> <span class="hljs-string">'function'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>The contents of a <code><script></code> block are encoded via UTF-16, so if any extended
|
||||
characters are used in the block, btoa will fail as it maxes out at UTF-8.
|
||||
See <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowBase64/Base64_encoding_and_decoding#The_Unicode_Problem">https://developer.mozilla.org/en-US/docs/Web/API/WindowBase64/Base64_encoding_and_decoding#The_Unicode_Problem</a>
|
||||
for the gory details, and for the solution implemented here.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> btoa encodeURIComponent(src).replace <span class="hljs-regexp">/%([0-9A-F]{2})/g</span>, <span class="hljs-function"><span class="hljs-params">(match, p1)</span> -></span>
|
||||
String.fromCharCode <span class="hljs-string">'0x'</span> + p1
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error(<span class="hljs-string">'Unable to base64 encode inline sourcemap.'</span>)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Function wrapper to add source file information to SyntaxErrors thrown by the
|
||||
lexer/parser/compiler.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">withPrettyErrors</span> = <span class="hljs-params">(fn)</span> -></span>
|
||||
(code, options = {}) ->
|
||||
<span class="hljs-keyword">try</span>
|
||||
fn.call @, code, options
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">if</span> <span class="hljs-keyword">typeof</span> code <span class="hljs-keyword">isnt</span> <span class="hljs-string">'string'</span> <span class="hljs-comment"># Support `CoffeeScript.nodes(tokens)`.</span>
|
||||
<span class="hljs-keyword">throw</span> helpers.updateSyntaxError err, code, options.filename</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>For each compiled file, save its source in memory in case we need to
|
||||
recompile it later. We might need to recompile if the first compilation
|
||||
didn’t create a source map (faster) but something went wrong and we need
|
||||
a stack trace. Assuming that most of the time, code isn’t throwing
|
||||
exceptions, it’s probably more efficient to compile twice only when we
|
||||
need a stack trace, rather than always generating a source map even when
|
||||
it’s not likely to be used. Save in form of <code>filename</code>: <code>(source)</code></p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>sources = {}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Also save source maps if generated, in form of <code>filename</code>: <code>(source map)</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>sourceMaps = {}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Compile CoffeeScript code to JavaScript, using the Coffee/Jison compiler.</p>
|
||||
<p>If <code>options.sourceMap</code> is specified, then <code>options.filename</code> must also be
|
||||
specified. All options that can be passed to <code>SourceMap#generate</code> may also
|
||||
be passed here.</p>
|
||||
<p>This returns a javascript string, unless <code>options.sourceMap</code> is passed,
|
||||
in which case this returns a <code>{js, v3SourceMap, sourceMap}</code>
|
||||
object, where sourceMap is a sourcemap.coffee#SourceMap object, handy for
|
||||
doing programmatic lookups.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.compile = compile = withPrettyErrors (code, options) ->
|
||||
{merge, extend} = helpers
|
||||
options = extend {}, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Always generate a source map if no filename is passed in, since without a
|
||||
a filename we have no way to retrieve this source later in the event that
|
||||
we need to recompile it to get a source map for <code>prepareStackTrace</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> generateSourceMap = options.sourceMap <span class="hljs-keyword">or</span> options.inlineMap <span class="hljs-keyword">or</span> <span class="hljs-keyword">not</span> options.filename?
|
||||
filename = options.filename <span class="hljs-keyword">or</span> <span class="hljs-string">'<anonymous>'</span>
|
||||
|
||||
sources[filename] = code
|
||||
map = <span class="hljs-keyword">new</span> SourceMap <span class="hljs-keyword">if</span> generateSourceMap
|
||||
|
||||
tokens = lexer.tokenize code, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Pass a list of referenced variables, so that generated variables won’t get
|
||||
the same name.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> options.referencedVars = (
|
||||
token[<span class="hljs-number">1</span>] <span class="hljs-keyword">for</span> token <span class="hljs-keyword">in</span> tokens <span class="hljs-keyword">when</span> token[<span class="hljs-number">0</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">'IDENTIFIER'</span>
|
||||
)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Check for import or export; if found, force bare mode.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">unless</span> options.bare? <span class="hljs-keyword">and</span> options.bare <span class="hljs-keyword">is</span> <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">for</span> token <span class="hljs-keyword">in</span> tokens
|
||||
<span class="hljs-keyword">if</span> token[<span class="hljs-number">0</span>] <span class="hljs-keyword">in</span> [<span class="hljs-string">'IMPORT'</span>, <span class="hljs-string">'EXPORT'</span>]
|
||||
options.bare = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">break</span>
|
||||
|
||||
fragments = parser.parse(tokens).compileToFragments options
|
||||
|
||||
currentLine = <span class="hljs-number">0</span>
|
||||
currentLine += <span class="hljs-number">1</span> <span class="hljs-keyword">if</span> options.header
|
||||
currentLine += <span class="hljs-number">1</span> <span class="hljs-keyword">if</span> options.shiftLine
|
||||
currentColumn = <span class="hljs-number">0</span>
|
||||
js = <span class="hljs-string">""</span>
|
||||
<span class="hljs-keyword">for</span> fragment <span class="hljs-keyword">in</span> fragments</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Update the sourcemap with data from each fragment.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> generateSourceMap</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>Do not include empty, whitespace, or semicolon-only fragments.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> fragment.locationData <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> <span class="hljs-regexp">/^[;\s]*$/</span>.test fragment.code
|
||||
map.add(
|
||||
[fragment.locationData.first_line, fragment.locationData.first_column]
|
||||
[currentLine, currentColumn]
|
||||
{noReplace: <span class="hljs-literal">true</span>})
|
||||
newLines = helpers.count fragment.code, <span class="hljs-string">"\n"</span>
|
||||
currentLine += newLines
|
||||
<span class="hljs-keyword">if</span> newLines
|
||||
currentColumn = fragment.code.length - (fragment.code.lastIndexOf(<span class="hljs-string">"\n"</span>) + <span class="hljs-number">1</span>)
|
||||
<span class="hljs-keyword">else</span>
|
||||
currentColumn += fragment.code.length</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>Copy the code from each fragment into the final JavaScript.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> js += fragment.code
|
||||
|
||||
<span class="hljs-keyword">if</span> options.header
|
||||
header = <span class="hljs-string">"Generated by CoffeeScript <span class="hljs-subst">#{@VERSION}</span>"</span>
|
||||
js = <span class="hljs-string">"// <span class="hljs-subst">#{header}</span>\n<span class="hljs-subst">#{js}</span>"</span>
|
||||
|
||||
<span class="hljs-keyword">if</span> generateSourceMap
|
||||
v3SourceMap = map.generate(options, code)
|
||||
sourceMaps[filename] = map
|
||||
|
||||
<span class="hljs-keyword">if</span> options.inlineMap
|
||||
encoded = base64encode JSON.stringify v3SourceMap
|
||||
sourceMapDataURI = <span class="hljs-string">"//# sourceMappingURL=data:application/json;base64,<span class="hljs-subst">#{encoded}</span>"</span>
|
||||
sourceURL = <span class="hljs-string">"//# sourceURL=<span class="hljs-subst">#{options.filename ? <span class="hljs-string">'coffeescript'</span>}</span>"</span>
|
||||
js = <span class="hljs-string">"<span class="hljs-subst">#{js}</span>\n<span class="hljs-subst">#{sourceMapDataURI}</span>\n<span class="hljs-subst">#{sourceURL}</span>"</span>
|
||||
|
||||
<span class="hljs-keyword">if</span> options.sourceMap
|
||||
{
|
||||
js
|
||||
sourceMap: map
|
||||
v3SourceMap: JSON.stringify v3SourceMap, <span class="hljs-literal">null</span>, <span class="hljs-number">2</span>
|
||||
}
|
||||
<span class="hljs-keyword">else</span>
|
||||
js</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>Tokenize a string of CoffeeScript code, and return the array of tokens.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.tokens = withPrettyErrors (code, options) ->
|
||||
lexer.tokenize code, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>Parse a string of CoffeeScript code or an array of lexed tokens, and
|
||||
return the AST. You can then compile it by calling <code>.compile()</code> on the root,
|
||||
or traverse it by using <code>.traverseChildren()</code> with a callback.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.nodes = withPrettyErrors (source, options) ->
|
||||
<span class="hljs-keyword">if</span> <span class="hljs-keyword">typeof</span> source <span class="hljs-keyword">is</span> <span class="hljs-string">'string'</span>
|
||||
parser.parse lexer.tokenize source, options
|
||||
<span class="hljs-keyword">else</span>
|
||||
parser.parse source</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Compile and execute a string of CoffeeScript (on the server), correctly
|
||||
setting <code>__filename</code>, <code>__dirname</code>, and relative <code>require()</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.run = <span class="hljs-function"><span class="hljs-params">(code, options = {})</span> -></span>
|
||||
mainModule = <span class="hljs-built_in">require</span>.main</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<p>Set the filename.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> mainModule.filename = process.argv[<span class="hljs-number">1</span>] =
|
||||
<span class="hljs-keyword">if</span> options.filename <span class="hljs-keyword">then</span> fs.realpathSync(options.filename) <span class="hljs-keyword">else</span> <span class="hljs-string">'<anonymous>'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
<p>Clear the module cache.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> mainModule.moduleCache <span class="hljs-keyword">and</span>= {}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>Assign paths for node_modules loading</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> dir = <span class="hljs-keyword">if</span> options.filename?
|
||||
path.dirname fs.realpathSync options.filename
|
||||
<span class="hljs-keyword">else</span>
|
||||
fs.realpathSync <span class="hljs-string">'.'</span>
|
||||
mainModule.paths = <span class="hljs-built_in">require</span>(<span class="hljs-string">'module'</span>)._nodeModulePaths dir</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-23">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-23">¶</a>
|
||||
</div>
|
||||
<p>Compile.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> helpers.isCoffee(mainModule.filename) <span class="hljs-keyword">or</span> <span class="hljs-built_in">require</span>.extensions
|
||||
answer = compile code, options
|
||||
code = answer.js ? answer
|
||||
|
||||
mainModule._compile code, mainModule.filename</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-24">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-24">¶</a>
|
||||
</div>
|
||||
<p>Compile and evaluate a string of CoffeeScript (in a Node.js-like environment).
|
||||
The CoffeeScript REPL uses this to run the input.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.eval = <span class="hljs-function"><span class="hljs-params">(code, options = {})</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> code = code.trim()
|
||||
createContext = vm.Script.createContext ? vm.createContext
|
||||
|
||||
isContext = vm.isContext ? (ctx) ->
|
||||
options.sandbox <span class="hljs-keyword">instanceof</span> createContext().constructor
|
||||
|
||||
<span class="hljs-keyword">if</span> createContext
|
||||
<span class="hljs-keyword">if</span> options.sandbox?
|
||||
<span class="hljs-keyword">if</span> isContext options.sandbox
|
||||
sandbox = options.sandbox
|
||||
<span class="hljs-keyword">else</span>
|
||||
sandbox = createContext()
|
||||
sandbox[k] = v <span class="hljs-keyword">for</span> own k, v <span class="hljs-keyword">of</span> options.sandbox
|
||||
sandbox.<span class="hljs-built_in">global</span> = sandbox.root = sandbox.GLOBAL = sandbox
|
||||
<span class="hljs-keyword">else</span>
|
||||
sandbox = <span class="hljs-built_in">global</span>
|
||||
sandbox.__filename = options.filename || <span class="hljs-string">'eval'</span>
|
||||
sandbox.__dirname = path.dirname sandbox.__filename</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-25">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-25">¶</a>
|
||||
</div>
|
||||
<p>define module/require only if they chose not to specify their own</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">unless</span> sandbox <span class="hljs-keyword">isnt</span> <span class="hljs-built_in">global</span> <span class="hljs-keyword">or</span> sandbox.<span class="hljs-built_in">module</span> <span class="hljs-keyword">or</span> sandbox.<span class="hljs-built_in">require</span>
|
||||
Module = <span class="hljs-built_in">require</span> <span class="hljs-string">'module'</span>
|
||||
sandbox.<span class="hljs-built_in">module</span> = _module = <span class="hljs-keyword">new</span> Module(options.modulename || <span class="hljs-string">'eval'</span>)
|
||||
sandbox.<span class="hljs-built_in">require</span> = _require = <span class="hljs-function"><span class="hljs-params">(path)</span> -></span> Module._load path, _module, <span class="hljs-literal">true</span>
|
||||
_module.filename = sandbox.__filename
|
||||
<span class="hljs-keyword">for</span> r <span class="hljs-keyword">in</span> Object.getOwnPropertyNames <span class="hljs-built_in">require</span> <span class="hljs-keyword">when</span> r <span class="hljs-keyword">not</span> <span class="hljs-keyword">in</span> [<span class="hljs-string">'paths'</span>, <span class="hljs-string">'arguments'</span>, <span class="hljs-string">'caller'</span>]
|
||||
_require[r] = <span class="hljs-built_in">require</span>[r]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-26">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-26">¶</a>
|
||||
</div>
|
||||
<p>use the same hack node currently uses for their own REPL</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> _require.paths = _module.paths = Module._nodeModulePaths process.cwd()
|
||||
_require.resolve = <span class="hljs-function"><span class="hljs-params">(request)</span> -></span> Module._resolveFilename request, _module
|
||||
o = {}
|
||||
o[k] = v <span class="hljs-keyword">for</span> own k, v <span class="hljs-keyword">of</span> options
|
||||
o.bare = <span class="hljs-literal">on</span> <span class="hljs-comment"># ensure return value</span>
|
||||
js = compile code, o
|
||||
<span class="hljs-keyword">if</span> sandbox <span class="hljs-keyword">is</span> <span class="hljs-built_in">global</span>
|
||||
vm.runInThisContext js
|
||||
<span class="hljs-keyword">else</span>
|
||||
vm.runInContext js, sandbox
|
||||
|
||||
exports.register = <span class="hljs-function">-></span> <span class="hljs-built_in">require</span> <span class="hljs-string">'./register'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-27">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-27">¶</a>
|
||||
</div>
|
||||
<p>Throw error with deprecation warning when depending upon implicit <code>require.extensions</code> registration</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> <span class="hljs-built_in">require</span>.extensions
|
||||
<span class="hljs-keyword">for</span> ext <span class="hljs-keyword">in</span> @FILE_EXTENSIONS <span class="hljs-keyword">then</span> <span class="hljs-keyword">do</span> (ext) ->
|
||||
<span class="hljs-built_in">require</span>.extensions[ext] ?= <span class="hljs-function">-></span>
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"""
|
||||
Use CoffeeScript.register() or require the coffeescript/register module to require <span class="hljs-subst">#{ext}</span> files.
|
||||
"""</span>
|
||||
|
||||
exports._compileFile = <span class="hljs-function"><span class="hljs-params">(filename, sourceMap = <span class="hljs-literal">no</span>, inlineMap = <span class="hljs-literal">no</span>)</span> -></span>
|
||||
raw = fs.readFileSync filename, <span class="hljs-string">'utf8'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-28">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-28">¶</a>
|
||||
</div>
|
||||
<p>Strip the Unicode byte order mark, if this file begins with one.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> stripped = <span class="hljs-keyword">if</span> raw.charCodeAt(<span class="hljs-number">0</span>) <span class="hljs-keyword">is</span> <span class="hljs-number">0xFEFF</span> <span class="hljs-keyword">then</span> raw.substring <span class="hljs-number">1</span> <span class="hljs-keyword">else</span> raw
|
||||
|
||||
<span class="hljs-keyword">try</span>
|
||||
answer = compile stripped, {
|
||||
filename, sourceMap, inlineMap
|
||||
sourceFiles: [filename]
|
||||
literate: helpers.isLiterate filename
|
||||
}
|
||||
<span class="hljs-keyword">catch</span> err</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-29">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-29">¶</a>
|
||||
</div>
|
||||
<p>As the filename and code of a dynamically loaded file will be different
|
||||
from the original file compiled with CoffeeScript.run, add that
|
||||
information to error so it can be pretty-printed later.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">throw</span> helpers.updateSyntaxError err, stripped, filename
|
||||
|
||||
answer</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-30">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-30">¶</a>
|
||||
</div>
|
||||
<p>Instantiate a Lexer for our use here.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>lexer = <span class="hljs-keyword">new</span> Lexer</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-31">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-31">¶</a>
|
||||
</div>
|
||||
<p>The real Lexer produces a generic stream of tokens. This object provides a
|
||||
thin wrapper around it, compatible with the Jison API. We can then pass it
|
||||
directly as a “Jison lexer”.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>parser.lexer =
|
||||
lex: <span class="hljs-function">-></span>
|
||||
token = parser.tokens[@pos++]
|
||||
<span class="hljs-keyword">if</span> token
|
||||
[tag, @yytext, @yylloc] = token
|
||||
parser.errorToken = token.origin <span class="hljs-keyword">or</span> token
|
||||
@yylineno = @yylloc.first_line
|
||||
<span class="hljs-keyword">else</span>
|
||||
tag = <span class="hljs-string">''</span>
|
||||
|
||||
tag
|
||||
setInput: <span class="hljs-function"><span class="hljs-params">(tokens)</span> -></span>
|
||||
parser.tokens = tokens
|
||||
@pos = <span class="hljs-number">0</span>
|
||||
upcomingInput: <span class="hljs-function">-></span>
|
||||
<span class="hljs-string">""</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-32">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-32">¶</a>
|
||||
</div>
|
||||
<p>Make all the AST nodes visible to the parser.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>parser.yy = <span class="hljs-built_in">require</span> <span class="hljs-string">'./nodes'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-33">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-33">¶</a>
|
||||
</div>
|
||||
<p>Override Jison’s default error handling function.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>parser.yy.parseError = <span class="hljs-function"><span class="hljs-params">(message, {token})</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-34">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-34">¶</a>
|
||||
</div>
|
||||
<p>Disregard Jison’s message, it contains redundant line number information.
|
||||
Disregard the token, we take its value directly from the lexer in case
|
||||
the error is caused by a generated token which might refer to its origin.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> {errorToken, tokens} = parser
|
||||
[errorTag, errorText, errorLoc] = errorToken
|
||||
|
||||
errorText = <span class="hljs-keyword">switch</span>
|
||||
<span class="hljs-keyword">when</span> errorToken <span class="hljs-keyword">is</span> tokens[tokens.length - <span class="hljs-number">1</span>]
|
||||
<span class="hljs-string">'end of input'</span>
|
||||
<span class="hljs-keyword">when</span> errorTag <span class="hljs-keyword">in</span> [<span class="hljs-string">'INDENT'</span>, <span class="hljs-string">'OUTDENT'</span>]
|
||||
<span class="hljs-string">'indentation'</span>
|
||||
<span class="hljs-keyword">when</span> errorTag <span class="hljs-keyword">in</span> [<span class="hljs-string">'IDENTIFIER'</span>, <span class="hljs-string">'NUMBER'</span>, <span class="hljs-string">'INFINITY'</span>, <span class="hljs-string">'STRING'</span>, <span class="hljs-string">'STRING_START'</span>, <span class="hljs-string">'REGEX'</span>, <span class="hljs-string">'REGEX_START'</span>]
|
||||
errorTag.replace(<span class="hljs-regexp">/_START$/</span>, <span class="hljs-string">''</span>).toLowerCase()
|
||||
<span class="hljs-keyword">else</span>
|
||||
helpers.nameWhitespaceCharacter errorText</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-35">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-35">¶</a>
|
||||
</div>
|
||||
<p>The second argument has a <code>loc</code> property, which should have the location
|
||||
data for this token. Unfortunately, Jison seems to send an outdated <code>loc</code>
|
||||
(from the previous token), so we take the location information directly
|
||||
from the lexer.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> helpers.throwSyntaxError <span class="hljs-string">"unexpected <span class="hljs-subst">#{errorText}</span>"</span>, errorLoc</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-36">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-36">¶</a>
|
||||
</div>
|
||||
<p>Based on <a href="http://v8.googlecode.com/svn/branches/bleeding_edge/src/messages.js">http://v8.googlecode.com/svn/branches/bleeding_edge/src/messages.js</a>
|
||||
Modified to handle sourceMap</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">formatSourcePosition</span> = <span class="hljs-params">(frame, getSourceMapping)</span> -></span>
|
||||
filename = <span class="hljs-literal">undefined</span>
|
||||
fileLocation = <span class="hljs-string">''</span>
|
||||
|
||||
<span class="hljs-keyword">if</span> frame.isNative()
|
||||
fileLocation = <span class="hljs-string">"native"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-keyword">if</span> frame.isEval()
|
||||
filename = frame.getScriptNameOrSourceURL()
|
||||
fileLocation = <span class="hljs-string">"<span class="hljs-subst">#{frame.getEvalOrigin()}</span>, "</span> <span class="hljs-keyword">unless</span> filename
|
||||
<span class="hljs-keyword">else</span>
|
||||
filename = frame.getFileName()
|
||||
|
||||
filename <span class="hljs-keyword">or</span>= <span class="hljs-string">"<anonymous>"</span>
|
||||
|
||||
line = frame.getLineNumber()
|
||||
column = frame.getColumnNumber()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-37">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-37">¶</a>
|
||||
</div>
|
||||
<p>Check for a sourceMap position</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> source = getSourceMapping filename, line, column
|
||||
fileLocation =
|
||||
<span class="hljs-keyword">if</span> source
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{filename}</span>:<span class="hljs-subst">#{source[<span class="hljs-number">0</span>]}</span>:<span class="hljs-subst">#{source[<span class="hljs-number">1</span>]}</span>"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{filename}</span>:<span class="hljs-subst">#{line}</span>:<span class="hljs-subst">#{column}</span>"</span>
|
||||
|
||||
functionName = frame.getFunctionName()
|
||||
isConstructor = frame.isConstructor()
|
||||
isMethodCall = <span class="hljs-keyword">not</span> (frame.isToplevel() <span class="hljs-keyword">or</span> isConstructor)
|
||||
|
||||
<span class="hljs-keyword">if</span> isMethodCall
|
||||
methodName = frame.getMethodName()
|
||||
typeName = frame.getTypeName()
|
||||
|
||||
<span class="hljs-keyword">if</span> functionName
|
||||
tp = <span class="hljs-keyword">as</span> = <span class="hljs-string">''</span>
|
||||
<span class="hljs-keyword">if</span> typeName <span class="hljs-keyword">and</span> functionName.indexOf typeName
|
||||
tp = <span class="hljs-string">"<span class="hljs-subst">#{typeName}</span>."</span>
|
||||
<span class="hljs-keyword">if</span> methodName <span class="hljs-keyword">and</span> functionName.indexOf(<span class="hljs-string">".<span class="hljs-subst">#{methodName}</span>"</span>) <span class="hljs-keyword">isnt</span> functionName.length - methodName.length - <span class="hljs-number">1</span>
|
||||
<span class="hljs-keyword">as</span> = <span class="hljs-string">" [as <span class="hljs-subst">#{methodName}</span>]"</span>
|
||||
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{tp}</span><span class="hljs-subst">#{functionName}</span><span class="hljs-subst">#{<span class="hljs-keyword">as</span>}</span> (<span class="hljs-subst">#{fileLocation}</span>)"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{typeName}</span>.<span class="hljs-subst">#{methodName <span class="hljs-keyword">or</span> <span class="hljs-string">'<anonymous>'</span>}</span> (<span class="hljs-subst">#{fileLocation}</span>)"</span>
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> isConstructor
|
||||
<span class="hljs-string">"new <span class="hljs-subst">#{functionName <span class="hljs-keyword">or</span> <span class="hljs-string">'<anonymous>'</span>}</span> (<span class="hljs-subst">#{fileLocation}</span>)"</span>
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> functionName
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{functionName}</span> (<span class="hljs-subst">#{fileLocation}</span>)"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
fileLocation
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">getSourceMap</span> = <span class="hljs-params">(filename)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> sourceMaps[filename]?
|
||||
sourceMaps[filename]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-38">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-38">¶</a>
|
||||
</div>
|
||||
<p>CoffeeScript compiled in a browser may get compiled with <code>options.filename</code>
|
||||
of <code><anonymous></code>, but the browser may request the stack trace with the
|
||||
filename of the script file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> sourceMaps[<span class="hljs-string">'<anonymous>'</span>]?
|
||||
sourceMaps[<span class="hljs-string">'<anonymous>'</span>]
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> sources[filename]?
|
||||
answer = compile sources[filename],
|
||||
filename: filename
|
||||
sourceMap: <span class="hljs-literal">yes</span>
|
||||
literate: helpers.isLiterate filename
|
||||
answer.sourceMap
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-39">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-39">¶</a>
|
||||
</div>
|
||||
<p>Based on <a href="http://goo.gl/ZTx1p">michaelficarra/CoffeeScriptRedux</a>
|
||||
NodeJS / V8 have no support for transforming positions in stack traces using
|
||||
sourceMap, so we must monkey-patch Error to display CoffeeScript source
|
||||
positions.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>Error.prepareStackTrace = <span class="hljs-function"><span class="hljs-params">(err, stack)</span> -></span>
|
||||
<span class="hljs-function"> <span class="hljs-title">getSourceMapping</span> = <span class="hljs-params">(filename, line, column)</span> -></span>
|
||||
sourceMap = getSourceMap filename
|
||||
answer = sourceMap.sourceLocation [line - <span class="hljs-number">1</span>, column - <span class="hljs-number">1</span>] <span class="hljs-keyword">if</span> sourceMap?
|
||||
<span class="hljs-keyword">if</span> answer? <span class="hljs-keyword">then</span> [answer[<span class="hljs-number">0</span>] + <span class="hljs-number">1</span>, answer[<span class="hljs-number">1</span>] + <span class="hljs-number">1</span>] <span class="hljs-keyword">else</span> <span class="hljs-literal">null</span>
|
||||
|
||||
frames = <span class="hljs-keyword">for</span> frame <span class="hljs-keyword">in</span> stack
|
||||
<span class="hljs-keyword">break</span> <span class="hljs-keyword">if</span> frame.getFunction() <span class="hljs-keyword">is</span> exports.run
|
||||
<span class="hljs-string">" at <span class="hljs-subst">#{formatSourcePosition frame, getSourceMapping}</span>"</span>
|
||||
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{err.toString()}</span>\n<span class="hljs-subst">#{frames.join <span class="hljs-string">'\n'</span>}</span>\n"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
882
docs/v2/annotated-source/command.html
Normal file
@@ -0,0 +1,882 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>command.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>command.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>The <code>coffee</code> utility. Handles command-line compilation of CoffeeScript
|
||||
into various forms: saved into <code>.js</code> files or printed to stdout
|
||||
or recompiled every time the source is saved,
|
||||
printed as a token stream or as the syntax tree, or launch an
|
||||
interactive REPL.</p>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>External dependencies.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>fs = <span class="hljs-built_in">require</span> <span class="hljs-string">'fs'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span>
|
||||
helpers = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
optparse = <span class="hljs-built_in">require</span> <span class="hljs-string">'./optparse'</span>
|
||||
CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffeescript'</span>
|
||||
{spawn, exec} = <span class="hljs-built_in">require</span> <span class="hljs-string">'child_process'</span>
|
||||
{EventEmitter} = <span class="hljs-built_in">require</span> <span class="hljs-string">'events'</span>
|
||||
|
||||
useWinPathSep = path.sep <span class="hljs-keyword">is</span> <span class="hljs-string">'\\'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Allow CoffeeScript to emit Node.js events.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>helpers.extend CoffeeScript, <span class="hljs-keyword">new</span> EventEmitter
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">printLine</span> = <span class="hljs-params">(line)</span> -></span> process.stdout.write line + <span class="hljs-string">'\n'</span>
|
||||
<span class="hljs-function"><span class="hljs-title">printWarn</span> = <span class="hljs-params">(line)</span> -></span> process.stderr.write line + <span class="hljs-string">'\n'</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">hidden</span> = <span class="hljs-params">(file)</span> -></span> <span class="hljs-regexp">/^\.|~$/</span>.test file</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>The help banner that is printed in conjunction with <code>-h</code>/<code>--help</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>BANNER = <span class="hljs-string">'''
|
||||
Usage: coffee [options] path/to/script.coffee -- [args]
|
||||
|
||||
If called without options, `coffee` will run your script.
|
||||
'''</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>The list of all the valid option flags that <code>coffee</code> knows how to handle.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>SWITCHES = [
|
||||
[<span class="hljs-string">'-b'</span>, <span class="hljs-string">'--bare'</span>, <span class="hljs-string">'compile without a top-level function wrapper'</span>]
|
||||
[<span class="hljs-string">'-c'</span>, <span class="hljs-string">'--compile'</span>, <span class="hljs-string">'compile to JavaScript and save as .js files'</span>]
|
||||
[<span class="hljs-string">'-e'</span>, <span class="hljs-string">'--eval'</span>, <span class="hljs-string">'pass a string from the command line as input'</span>]
|
||||
[<span class="hljs-string">'-h'</span>, <span class="hljs-string">'--help'</span>, <span class="hljs-string">'display this help message'</span>]
|
||||
[<span class="hljs-string">'-i'</span>, <span class="hljs-string">'--interactive'</span>, <span class="hljs-string">'run an interactive CoffeeScript REPL'</span>]
|
||||
[<span class="hljs-string">'-j'</span>, <span class="hljs-string">'--join [FILE]'</span>, <span class="hljs-string">'concatenate the source CoffeeScript before compiling'</span>]
|
||||
[<span class="hljs-string">'-m'</span>, <span class="hljs-string">'--map'</span>, <span class="hljs-string">'generate source map and save as .js.map files'</span>]
|
||||
[<span class="hljs-string">'-M'</span>, <span class="hljs-string">'--inline-map'</span>, <span class="hljs-string">'generate source map and include it directly in output'</span>]
|
||||
[<span class="hljs-string">'-n'</span>, <span class="hljs-string">'--nodes'</span>, <span class="hljs-string">'print out the parse tree that the parser produces'</span>]
|
||||
[ <span class="hljs-string">'--nodejs [ARGS]'</span>, <span class="hljs-string">'pass options directly to the "node" binary'</span>]
|
||||
[ <span class="hljs-string">'--no-header'</span>, <span class="hljs-string">'suppress the "Generated by" header'</span>]
|
||||
[<span class="hljs-string">'-o'</span>, <span class="hljs-string">'--output [DIR]'</span>, <span class="hljs-string">'set the output directory for compiled JavaScript'</span>]
|
||||
[<span class="hljs-string">'-p'</span>, <span class="hljs-string">'--print'</span>, <span class="hljs-string">'print out the compiled JavaScript'</span>]
|
||||
[<span class="hljs-string">'-r'</span>, <span class="hljs-string">'--require [MODULE*]'</span>, <span class="hljs-string">'require the given module before eval or REPL'</span>]
|
||||
[<span class="hljs-string">'-s'</span>, <span class="hljs-string">'--stdio'</span>, <span class="hljs-string">'listen for and compile scripts over stdio'</span>]
|
||||
[<span class="hljs-string">'-l'</span>, <span class="hljs-string">'--literate'</span>, <span class="hljs-string">'treat stdio as literate style coffeescript'</span>]
|
||||
[<span class="hljs-string">'-t'</span>, <span class="hljs-string">'--tokens'</span>, <span class="hljs-string">'print out the tokens that the lexer/rewriter produce'</span>]
|
||||
[<span class="hljs-string">'-v'</span>, <span class="hljs-string">'--version'</span>, <span class="hljs-string">'display the version number'</span>]
|
||||
[<span class="hljs-string">'-w'</span>, <span class="hljs-string">'--watch'</span>, <span class="hljs-string">'watch scripts for changes and rerun commands'</span>]
|
||||
]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Top-level objects shared by all the functions.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>opts = {}
|
||||
sources = []
|
||||
sourceCode = []
|
||||
notSources = {}
|
||||
watchedDirs = {}
|
||||
optionParser = <span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Run <code>coffee</code> by parsing passed options and determining what action to take.
|
||||
Many flags cause us to divert before compiling anything. Flags passed after
|
||||
<code>--</code> will be passed verbatim to your script as arguments in <code>process.argv</code></p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.run = <span class="hljs-function">-></span>
|
||||
parseOptions()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Make the REPL <em>CLI</em> use the global context so as to (a) be consistent with the
|
||||
<code>node</code> REPL CLI and, therefore, (b) make packages that modify native prototypes
|
||||
(such as ‘colors’ and ‘sugar’) work as expected.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> replCliOpts = useGlobal: <span class="hljs-literal">yes</span>
|
||||
opts.prelude = makePrelude opts.<span class="hljs-built_in">require</span> <span class="hljs-keyword">if</span> opts.<span class="hljs-built_in">require</span>
|
||||
replCliOpts.prelude = opts.prelude
|
||||
<span class="hljs-keyword">return</span> forkNode() <span class="hljs-keyword">if</span> opts.nodejs
|
||||
<span class="hljs-keyword">return</span> usage() <span class="hljs-keyword">if</span> opts.help
|
||||
<span class="hljs-keyword">return</span> version() <span class="hljs-keyword">if</span> opts.version
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-built_in">require</span>(<span class="hljs-string">'./repl'</span>).start(replCliOpts) <span class="hljs-keyword">if</span> opts.interactive
|
||||
<span class="hljs-keyword">return</span> compileStdio() <span class="hljs-keyword">if</span> opts.stdio
|
||||
<span class="hljs-keyword">return</span> compileScript <span class="hljs-literal">null</span>, opts.arguments[<span class="hljs-number">0</span>] <span class="hljs-keyword">if</span> opts.eval
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-built_in">require</span>(<span class="hljs-string">'./repl'</span>).start(replCliOpts) <span class="hljs-keyword">unless</span> opts.arguments.length
|
||||
literals = <span class="hljs-keyword">if</span> opts.run <span class="hljs-keyword">then</span> opts.arguments.splice <span class="hljs-number">1</span> <span class="hljs-keyword">else</span> []
|
||||
process.argv = process.argv[<span class="hljs-number">0.</span><span class="hljs-number">.1</span>].concat literals
|
||||
process.argv[<span class="hljs-number">0</span>] = <span class="hljs-string">'coffee'</span>
|
||||
|
||||
opts.output = path.resolve opts.output <span class="hljs-keyword">if</span> opts.output
|
||||
<span class="hljs-keyword">if</span> opts.join
|
||||
opts.join = path.resolve opts.join
|
||||
<span class="hljs-built_in">console</span>.error <span class="hljs-string">'''
|
||||
|
||||
The --join option is deprecated and will be removed in a future version.
|
||||
|
||||
If for some reason it's necessary to share local variables between files,
|
||||
replace...
|
||||
|
||||
$ coffee --compile --join bundle.js -- a.coffee b.coffee c.coffee
|
||||
|
||||
with...
|
||||
|
||||
$ cat a.coffee b.coffee c.coffee | coffee --compile --stdio > bundle.js
|
||||
|
||||
'''</span>
|
||||
<span class="hljs-keyword">for</span> source <span class="hljs-keyword">in</span> opts.arguments
|
||||
source = path.resolve source
|
||||
compilePath source, <span class="hljs-literal">yes</span>, source
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">makePrelude</span> = <span class="hljs-params">(requires)</span> -></span>
|
||||
requires.map (<span class="hljs-built_in">module</span>) ->
|
||||
[_, name, <span class="hljs-built_in">module</span>] = match <span class="hljs-keyword">if</span> match = <span class="hljs-built_in">module</span>.match(<span class="hljs-regexp">/^(.*)=(.*)$/</span>)
|
||||
name ||= helpers.baseFileName <span class="hljs-built_in">module</span>, <span class="hljs-literal">yes</span>, useWinPathSep
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{name}</span> = require('<span class="hljs-subst">#{<span class="hljs-built_in">module</span>}</span>')"</span>
|
||||
.join <span class="hljs-string">';'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Compile a path, which could be a script or a directory. If a directory
|
||||
is passed, recursively compile all ‘.coffee’, ‘.litcoffee’, and ‘.coffee.md’
|
||||
extension source files in it and all subdirectories.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">compilePath</span> = <span class="hljs-params">(source, topLevel, base)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> source <span class="hljs-keyword">in</span> sources <span class="hljs-keyword">or</span>
|
||||
watchedDirs[source] <span class="hljs-keyword">or</span>
|
||||
<span class="hljs-keyword">not</span> topLevel <span class="hljs-keyword">and</span> (notSources[source] <span class="hljs-keyword">or</span> hidden source)
|
||||
<span class="hljs-keyword">try</span>
|
||||
stats = fs.statSync source
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">if</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-built_in">console</span>.error <span class="hljs-string">"File not found: <span class="hljs-subst">#{source}</span>"</span>
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
<span class="hljs-keyword">throw</span> err
|
||||
<span class="hljs-keyword">if</span> stats.isDirectory()
|
||||
<span class="hljs-keyword">if</span> path.basename(source) <span class="hljs-keyword">is</span> <span class="hljs-string">'node_modules'</span>
|
||||
notSources[source] = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">return</span>
|
||||
<span class="hljs-keyword">if</span> opts.run
|
||||
compilePath findDirectoryIndex(source), topLevel, base
|
||||
<span class="hljs-keyword">return</span>
|
||||
watchDir source, base <span class="hljs-keyword">if</span> opts.watch
|
||||
<span class="hljs-keyword">try</span>
|
||||
files = fs.readdirSync source
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">if</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span> <span class="hljs-keyword">then</span> <span class="hljs-keyword">return</span> <span class="hljs-keyword">else</span> <span class="hljs-keyword">throw</span> err
|
||||
<span class="hljs-keyword">for</span> file <span class="hljs-keyword">in</span> files
|
||||
compilePath (path.join source, file), <span class="hljs-literal">no</span>, base
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> topLevel <span class="hljs-keyword">or</span> helpers.isCoffee source
|
||||
sources.push source
|
||||
sourceCode.push <span class="hljs-literal">null</span>
|
||||
<span class="hljs-keyword">delete</span> notSources[source]
|
||||
watch source, base <span class="hljs-keyword">if</span> opts.watch
|
||||
<span class="hljs-keyword">try</span>
|
||||
code = fs.readFileSync source
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">if</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span> <span class="hljs-keyword">then</span> <span class="hljs-keyword">return</span> <span class="hljs-keyword">else</span> <span class="hljs-keyword">throw</span> err
|
||||
compileScript(source, code.toString(), base)
|
||||
<span class="hljs-keyword">else</span>
|
||||
notSources[source] = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">findDirectoryIndex</span> = <span class="hljs-params">(source)</span> -></span>
|
||||
<span class="hljs-keyword">for</span> ext <span class="hljs-keyword">in</span> CoffeeScript.FILE_EXTENSIONS
|
||||
index = path.join source, <span class="hljs-string">"index<span class="hljs-subst">#{ext}</span>"</span>
|
||||
<span class="hljs-keyword">try</span>
|
||||
<span class="hljs-keyword">return</span> index <span class="hljs-keyword">if</span> (fs.statSync index).isFile()
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-built_in">console</span>.error <span class="hljs-string">"Missing index.coffee or index.litcoffee in <span class="hljs-subst">#{source}</span>"</span>
|
||||
process.exit <span class="hljs-number">1</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Compile a single source script, containing the given code, according to the
|
||||
requested options. If evaluating the script directly sets <code>__filename</code>,
|
||||
<code>__dirname</code> and <code>module.filename</code> to be correct relative to the script’s path.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">compileScript</span> = <span class="hljs-params">(file, input, base = <span class="hljs-literal">null</span>)</span> -></span>
|
||||
o = opts
|
||||
options = compileOptions file, base
|
||||
<span class="hljs-keyword">try</span>
|
||||
t = task = {file, input, options}
|
||||
CoffeeScript.emit <span class="hljs-string">'compile'</span>, task
|
||||
<span class="hljs-keyword">if</span> o.tokens
|
||||
printTokens CoffeeScript.tokens t.input, t.options
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.nodes
|
||||
printLine CoffeeScript.nodes(t.input, t.options).toString().trim()
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.run
|
||||
CoffeeScript.register()
|
||||
CoffeeScript.eval opts.prelude, t.options <span class="hljs-keyword">if</span> opts.prelude
|
||||
CoffeeScript.run t.input, t.options
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.join <span class="hljs-keyword">and</span> t.file <span class="hljs-keyword">isnt</span> o.join
|
||||
t.input = helpers.invertLiterate t.input <span class="hljs-keyword">if</span> helpers.isLiterate file
|
||||
sourceCode[sources.indexOf(t.file)] = t.input
|
||||
compileJoin()
|
||||
<span class="hljs-keyword">else</span>
|
||||
compiled = CoffeeScript.compile t.input, t.options
|
||||
t.output = compiled
|
||||
<span class="hljs-keyword">if</span> o.map
|
||||
t.output = compiled.js
|
||||
t.sourceMap = compiled.v3SourceMap
|
||||
|
||||
CoffeeScript.emit <span class="hljs-string">'success'</span>, task
|
||||
<span class="hljs-keyword">if</span> o.<span class="hljs-built_in">print</span>
|
||||
printLine t.output.trim()
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> o.compile <span class="hljs-keyword">or</span> o.map
|
||||
writeJs base, t.file, t.output, options.jsPath, t.sourceMap
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
CoffeeScript.emit <span class="hljs-string">'failure'</span>, err, task
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> CoffeeScript.listeners(<span class="hljs-string">'failure'</span>).length
|
||||
message = err?.stack <span class="hljs-keyword">or</span> <span class="hljs-string">"<span class="hljs-subst">#{err}</span>"</span>
|
||||
<span class="hljs-keyword">if</span> o.watch
|
||||
printLine message + <span class="hljs-string">'\x07'</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
printWarn message
|
||||
process.exit <span class="hljs-number">1</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Attach the appropriate listeners to compile scripts incoming over <strong>stdin</strong>,
|
||||
and write them back to <strong>stdout</strong>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">compileStdio</span> = -></span>
|
||||
buffers = []
|
||||
stdin = process.openStdin()
|
||||
stdin.<span class="hljs-literal">on</span> <span class="hljs-string">'data'</span>, <span class="hljs-function"><span class="hljs-params">(buffer)</span> -></span>
|
||||
buffers.push buffer <span class="hljs-keyword">if</span> buffer
|
||||
stdin.<span class="hljs-literal">on</span> <span class="hljs-string">'end'</span>, <span class="hljs-function">-></span>
|
||||
compileScript <span class="hljs-literal">null</span>, Buffer.concat(buffers).toString()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>If all of the source files are done being read, concatenate and compile
|
||||
them together.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>joinTimeout = <span class="hljs-literal">null</span>
|
||||
<span class="hljs-function"><span class="hljs-title">compileJoin</span> = -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> opts.join
|
||||
<span class="hljs-keyword">unless</span> sourceCode.some(<span class="hljs-function"><span class="hljs-params">(code)</span> -></span> code <span class="hljs-keyword">is</span> <span class="hljs-literal">null</span>)
|
||||
clearTimeout joinTimeout
|
||||
joinTimeout = wait <span class="hljs-number">100</span>, <span class="hljs-function">-></span>
|
||||
compileScript opts.join, sourceCode.join(<span class="hljs-string">'\n'</span>), opts.join</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Watch a source CoffeeScript file using <code>fs.watch</code>, recompiling it every
|
||||
time the file is updated. May be used in combination with other options,
|
||||
such as <code>--print</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">watch</span> = <span class="hljs-params">(source, base)</span> -></span>
|
||||
watcher = <span class="hljs-literal">null</span>
|
||||
prevStats = <span class="hljs-literal">null</span>
|
||||
compileTimeout = <span class="hljs-literal">null</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">watchErr</span> = <span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> source <span class="hljs-keyword">in</span> sources
|
||||
<span class="hljs-keyword">try</span>
|
||||
rewatch()
|
||||
compile()
|
||||
<span class="hljs-keyword">catch</span>
|
||||
removeSource source, base
|
||||
compileJoin()
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">compile</span> = -></span>
|
||||
clearTimeout compileTimeout
|
||||
compileTimeout = wait <span class="hljs-number">25</span>, <span class="hljs-function">-></span>
|
||||
fs.stat source, <span class="hljs-function"><span class="hljs-params">(err, stats)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> watchErr err <span class="hljs-keyword">if</span> err
|
||||
<span class="hljs-keyword">return</span> rewatch() <span class="hljs-keyword">if</span> prevStats <span class="hljs-keyword">and</span>
|
||||
stats.size <span class="hljs-keyword">is</span> prevStats.size <span class="hljs-keyword">and</span>
|
||||
stats.mtime.getTime() <span class="hljs-keyword">is</span> prevStats.mtime.getTime()
|
||||
prevStats = stats
|
||||
fs.readFile source, <span class="hljs-function"><span class="hljs-params">(err, code)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> watchErr err <span class="hljs-keyword">if</span> err
|
||||
compileScript(source, code.toString(), base)
|
||||
rewatch()
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">startWatcher</span> = -></span>
|
||||
watcher = fs.watch source
|
||||
.<span class="hljs-literal">on</span> <span class="hljs-string">'change'</span>, compile
|
||||
.<span class="hljs-literal">on</span> <span class="hljs-string">'error'</span>, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'EPERM'</span>
|
||||
removeSource source, base
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">rewatch</span> = -></span>
|
||||
watcher?.close()
|
||||
startWatcher()
|
||||
|
||||
<span class="hljs-keyword">try</span>
|
||||
startWatcher()
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
watchErr err</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Watch a directory of files for new additions.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">watchDir</span> = <span class="hljs-params">(source, base)</span> -></span>
|
||||
watcher = <span class="hljs-literal">null</span>
|
||||
readdirTimeout = <span class="hljs-literal">null</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">startWatcher</span> = -></span>
|
||||
watcher = fs.watch source
|
||||
.<span class="hljs-literal">on</span> <span class="hljs-string">'error'</span>, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'EPERM'</span>
|
||||
stopWatcher()
|
||||
.<span class="hljs-literal">on</span> <span class="hljs-string">'change'</span>, <span class="hljs-function">-></span>
|
||||
clearTimeout readdirTimeout
|
||||
readdirTimeout = wait <span class="hljs-number">25</span>, <span class="hljs-function">-></span>
|
||||
<span class="hljs-keyword">try</span>
|
||||
files = fs.readdirSync source
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-keyword">return</span> stopWatcher()
|
||||
<span class="hljs-keyword">for</span> file <span class="hljs-keyword">in</span> files
|
||||
compilePath (path.join source, file), <span class="hljs-literal">no</span>, base
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">stopWatcher</span> = -></span>
|
||||
watcher.close()
|
||||
removeSourceDir source, base
|
||||
|
||||
watchedDirs[source] = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">try</span>
|
||||
startWatcher()
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">is</span> <span class="hljs-string">'ENOENT'</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">removeSourceDir</span> = <span class="hljs-params">(source, base)</span> -></span>
|
||||
<span class="hljs-keyword">delete</span> watchedDirs[source]
|
||||
sourcesChanged = <span class="hljs-literal">no</span>
|
||||
<span class="hljs-keyword">for</span> file <span class="hljs-keyword">in</span> sources <span class="hljs-keyword">when</span> source <span class="hljs-keyword">is</span> path.dirname file
|
||||
removeSource file, base
|
||||
sourcesChanged = <span class="hljs-literal">yes</span>
|
||||
compileJoin() <span class="hljs-keyword">if</span> sourcesChanged</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>Remove a file from our source list, and source code cache. Optionally remove
|
||||
the compiled JS version as well.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">removeSource</span> = <span class="hljs-params">(source, base)</span> -></span>
|
||||
index = sources.indexOf source
|
||||
sources.splice index, <span class="hljs-number">1</span>
|
||||
sourceCode.splice index, <span class="hljs-number">1</span>
|
||||
<span class="hljs-keyword">unless</span> opts.join
|
||||
silentUnlink outputPath source, base
|
||||
silentUnlink outputPath source, base, <span class="hljs-string">'.js.map'</span>
|
||||
timeLog <span class="hljs-string">"removed <span class="hljs-subst">#{source}</span>"</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">silentUnlink</span> = <span class="hljs-params">(path)</span> -></span>
|
||||
<span class="hljs-keyword">try</span>
|
||||
fs.unlinkSync path
|
||||
<span class="hljs-keyword">catch</span> err
|
||||
<span class="hljs-keyword">throw</span> err <span class="hljs-keyword">unless</span> err.code <span class="hljs-keyword">in</span> [<span class="hljs-string">'ENOENT'</span>, <span class="hljs-string">'EPERM'</span>]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>Get the corresponding output JavaScript path for a source file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">outputPath</span> = <span class="hljs-params">(source, base, extension=<span class="hljs-string">".js"</span>)</span> -></span>
|
||||
basename = helpers.baseFileName source, <span class="hljs-literal">yes</span>, useWinPathSep
|
||||
srcDir = path.dirname source
|
||||
<span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> opts.output
|
||||
dir = srcDir
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> source <span class="hljs-keyword">is</span> base
|
||||
dir = opts.output
|
||||
<span class="hljs-keyword">else</span>
|
||||
dir = path.join opts.output, path.relative base, srcDir
|
||||
path.join dir, basename + extension</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>Recursively mkdir, like <code>mkdir -p</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">mkdirp</span> = <span class="hljs-params">(dir, fn)</span> -></span>
|
||||
mode = <span class="hljs-number">0</span>o777 & ~process.umask()
|
||||
|
||||
<span class="hljs-keyword">do</span> mkdirs = <span class="hljs-function"><span class="hljs-params">(p = dir, fn)</span> -></span>
|
||||
fs.exists p, <span class="hljs-function"><span class="hljs-params">(exists)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> exists
|
||||
fn()
|
||||
<span class="hljs-keyword">else</span>
|
||||
mkdirs path.dirname(p), <span class="hljs-function">-></span>
|
||||
fs.mkdir p, mode, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> fn err <span class="hljs-keyword">if</span> err
|
||||
fn()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>Write out a JavaScript source file with the compiled code. By default, files
|
||||
are written out in <code>cwd</code> as <code>.js</code> files with the same name, but the output
|
||||
directory can be customized with <code>--output</code>.</p>
|
||||
<p>If <code>generatedSourceMap</code> is provided, this will write a <code>.js.map</code> file into the
|
||||
same directory as the <code>.js</code> file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">writeJs</span> = <span class="hljs-params">(base, sourcePath, js, jsPath, generatedSourceMap = <span class="hljs-literal">null</span>)</span> -></span>
|
||||
sourceMapPath = outputPath sourcePath, base, <span class="hljs-string">".js.map"</span>
|
||||
jsDir = path.dirname jsPath
|
||||
<span class="hljs-function"> <span class="hljs-title">compile</span> = -></span>
|
||||
<span class="hljs-keyword">if</span> opts.compile
|
||||
js = <span class="hljs-string">' '</span> <span class="hljs-keyword">if</span> js.length <= <span class="hljs-number">0</span>
|
||||
<span class="hljs-keyword">if</span> generatedSourceMap <span class="hljs-keyword">then</span> js = <span class="hljs-string">"<span class="hljs-subst">#{js}</span>\n//# sourceMappingURL=<span class="hljs-subst">#{helpers.baseFileName sourceMapPath, <span class="hljs-literal">no</span>, useWinPathSep}</span>\n"</span>
|
||||
fs.writeFile jsPath, js, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> err
|
||||
printLine err.message
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> opts.compile <span class="hljs-keyword">and</span> opts.watch
|
||||
timeLog <span class="hljs-string">"compiled <span class="hljs-subst">#{sourcePath}</span>"</span>
|
||||
<span class="hljs-keyword">if</span> generatedSourceMap
|
||||
fs.writeFile sourceMapPath, generatedSourceMap, <span class="hljs-function"><span class="hljs-params">(err)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> err
|
||||
printLine <span class="hljs-string">"Could not write source map: <span class="hljs-subst">#{err.message}</span>"</span>
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
fs.exists jsDir, <span class="hljs-function"><span class="hljs-params">(itExists)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> itExists <span class="hljs-keyword">then</span> compile() <span class="hljs-keyword">else</span> mkdirp jsDir, compile</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Convenience for cleaner setTimeouts.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">wait</span> = <span class="hljs-params">(milliseconds, func)</span> -></span> setTimeout func, milliseconds</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<p>When watching scripts, it’s useful to log changes with the timestamp.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">timeLog</span> = <span class="hljs-params">(message)</span> -></span>
|
||||
<span class="hljs-built_in">console</span>.log <span class="hljs-string">"<span class="hljs-subst">#{(<span class="hljs-keyword">new</span> Date).toLocaleTimeString()}</span> - <span class="hljs-subst">#{message}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
<p>Pretty-print a stream of tokens, sans location data.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">printTokens</span> = <span class="hljs-params">(tokens)</span> -></span>
|
||||
strings = <span class="hljs-keyword">for</span> token <span class="hljs-keyword">in</span> tokens
|
||||
tag = token[<span class="hljs-number">0</span>]
|
||||
value = token[<span class="hljs-number">1</span>].toString().replace(<span class="hljs-regexp">/\n/</span>, <span class="hljs-string">'\\n'</span>)
|
||||
<span class="hljs-string">"[<span class="hljs-subst">#{tag}</span> <span class="hljs-subst">#{value}</span>]"</span>
|
||||
printLine strings.join(<span class="hljs-string">' '</span>)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>Use the <a href="optparse.html">OptionParser module</a> to extract all options from
|
||||
<code>process.argv</code> that are specified in <code>SWITCHES</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">parseOptions</span> = -></span>
|
||||
optionParser = <span class="hljs-keyword">new</span> optparse.OptionParser SWITCHES, BANNER
|
||||
o = opts = optionParser.parse process.argv[<span class="hljs-number">2.</span>.]
|
||||
o.compile <span class="hljs-keyword">or</span>= !!o.output
|
||||
o.run = <span class="hljs-keyword">not</span> (o.compile <span class="hljs-keyword">or</span> o.<span class="hljs-built_in">print</span> <span class="hljs-keyword">or</span> o.map)
|
||||
o.<span class="hljs-built_in">print</span> = !! (o.<span class="hljs-built_in">print</span> <span class="hljs-keyword">or</span> (o.eval <span class="hljs-keyword">or</span> o.stdio <span class="hljs-keyword">and</span> o.compile))</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-23">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-23">¶</a>
|
||||
</div>
|
||||
<p>The compile-time options to pass to the CoffeeScript compiler.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">compileOptions</span> = <span class="hljs-params">(filename, base)</span> -></span>
|
||||
answer = {
|
||||
filename
|
||||
literate: opts.literate <span class="hljs-keyword">or</span> helpers.isLiterate(filename)
|
||||
bare: opts.bare
|
||||
header: opts.compile <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> opts[<span class="hljs-string">'no-header'</span>]
|
||||
sourceMap: opts.map
|
||||
inlineMap: opts[<span class="hljs-string">'inline-map'</span>]
|
||||
}
|
||||
<span class="hljs-keyword">if</span> filename
|
||||
<span class="hljs-keyword">if</span> base
|
||||
cwd = process.cwd()
|
||||
jsPath = outputPath filename, base
|
||||
jsDir = path.dirname jsPath
|
||||
answer = helpers.merge answer, {
|
||||
jsPath
|
||||
sourceRoot: path.relative jsDir, cwd
|
||||
sourceFiles: [path.relative cwd, filename]
|
||||
generatedFile: helpers.baseFileName(jsPath, <span class="hljs-literal">no</span>, useWinPathSep)
|
||||
}
|
||||
<span class="hljs-keyword">else</span>
|
||||
answer = helpers.merge answer,
|
||||
sourceRoot: <span class="hljs-string">""</span>
|
||||
sourceFiles: [helpers.baseFileName filename, <span class="hljs-literal">no</span>, useWinPathSep]
|
||||
generatedFile: helpers.baseFileName(filename, <span class="hljs-literal">yes</span>, useWinPathSep) + <span class="hljs-string">".js"</span>
|
||||
answer</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-24">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-24">¶</a>
|
||||
</div>
|
||||
<p>Start up a new Node.js instance with the arguments in <code>--nodejs</code> passed to
|
||||
the <code>node</code> binary, preserving the other options.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">forkNode</span> = -></span>
|
||||
nodeArgs = opts.nodejs.split <span class="hljs-regexp">/\s+/</span>
|
||||
args = process.argv[<span class="hljs-number">1.</span>.]
|
||||
args.splice args.indexOf(<span class="hljs-string">'--nodejs'</span>), <span class="hljs-number">2</span>
|
||||
p = spawn process.execPath, nodeArgs.concat(args),
|
||||
cwd: process.cwd()
|
||||
env: process.env
|
||||
stdio: [<span class="hljs-number">0</span>, <span class="hljs-number">1</span>, <span class="hljs-number">2</span>]
|
||||
p.<span class="hljs-literal">on</span> <span class="hljs-string">'exit'</span>, <span class="hljs-function"><span class="hljs-params">(code)</span> -></span> process.exit code</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-25">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-25">¶</a>
|
||||
</div>
|
||||
<p>Print the <code>--help</code> usage message and exit. Deprecated switches are not
|
||||
shown.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">usage</span> = -></span>
|
||||
printLine (<span class="hljs-keyword">new</span> optparse.OptionParser SWITCHES, BANNER).help()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-26">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-26">¶</a>
|
||||
</div>
|
||||
<p>Print the <code>--version</code> message and exit.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">version</span> = -></span>
|
||||
printLine <span class="hljs-string">"CoffeeScript version <span class="hljs-subst">#{CoffeeScript.VERSION}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
518
docs/v2/annotated-source/docco.css
Normal file
@@ -0,0 +1,518 @@
|
||||
/*--------------------- Typography ----------------------------*/
|
||||
|
||||
@font-face {
|
||||
font-family: 'aller-light';
|
||||
src: url('public/fonts/aller-light.eot');
|
||||
src: url('public/fonts/aller-light.eot?#iefix') format('embedded-opentype'),
|
||||
url('public/fonts/aller-light.woff') format('woff'),
|
||||
url('public/fonts/aller-light.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'aller-bold';
|
||||
src: url('public/fonts/aller-bold.eot');
|
||||
src: url('public/fonts/aller-bold.eot?#iefix') format('embedded-opentype'),
|
||||
url('public/fonts/aller-bold.woff') format('woff'),
|
||||
url('public/fonts/aller-bold.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'roboto-black';
|
||||
src: url('public/fonts/roboto-black.eot');
|
||||
src: url('public/fonts/roboto-black.eot?#iefix') format('embedded-opentype'),
|
||||
url('public/fonts/roboto-black.woff') format('woff'),
|
||||
url('public/fonts/roboto-black.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
/*--------------------- Layout ----------------------------*/
|
||||
html { height: 100%; }
|
||||
body {
|
||||
font-family: "aller-light";
|
||||
font-size: 14px;
|
||||
line-height: 18px;
|
||||
color: #30404f;
|
||||
margin: 0; padding: 0;
|
||||
height:100%;
|
||||
}
|
||||
#container { min-height: 100%; }
|
||||
|
||||
a {
|
||||
color: #000;
|
||||
}
|
||||
|
||||
b, strong {
|
||||
font-weight: normal;
|
||||
font-family: "aller-bold";
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 15px 0 0px;
|
||||
}
|
||||
.annotation ul, .annotation ol {
|
||||
margin: 25px 0;
|
||||
}
|
||||
.annotation ul li, .annotation ol li {
|
||||
font-size: 14px;
|
||||
line-height: 18px;
|
||||
margin: 10px 0;
|
||||
}
|
||||
|
||||
h1, h2, h3, h4, h5, h6 {
|
||||
color: #112233;
|
||||
line-height: 1em;
|
||||
font-weight: normal;
|
||||
font-family: "roboto-black";
|
||||
text-transform: uppercase;
|
||||
margin: 30px 0 15px 0;
|
||||
}
|
||||
|
||||
h1 {
|
||||
margin-top: 40px;
|
||||
}
|
||||
h2 {
|
||||
font-size: 1.26em;
|
||||
}
|
||||
|
||||
hr {
|
||||
border: 0;
|
||||
background: 1px #ddd;
|
||||
height: 1px;
|
||||
margin: 20px 0;
|
||||
}
|
||||
|
||||
pre, tt, code {
|
||||
font-size: 12px; line-height: 16px;
|
||||
font-family: Menlo, Monaco, Consolas, "Lucida Console", monospace;
|
||||
margin: 0; padding: 0;
|
||||
}
|
||||
.annotation pre {
|
||||
display: block;
|
||||
margin: 0;
|
||||
padding: 7px 10px;
|
||||
background: #fcfcfc;
|
||||
-moz-box-shadow: inset 0 0 10px rgba(0,0,0,0.1);
|
||||
-webkit-box-shadow: inset 0 0 10px rgba(0,0,0,0.1);
|
||||
box-shadow: inset 0 0 10px rgba(0,0,0,0.1);
|
||||
overflow-x: auto;
|
||||
}
|
||||
.annotation pre code {
|
||||
border: 0;
|
||||
padding: 0;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
|
||||
blockquote {
|
||||
border-left: 5px solid #ccc;
|
||||
margin: 0;
|
||||
padding: 1px 0 1px 1em;
|
||||
}
|
||||
.sections blockquote p {
|
||||
font-family: Menlo, Consolas, Monaco, monospace;
|
||||
font-size: 12px; line-height: 16px;
|
||||
color: #999;
|
||||
margin: 10px 0 0;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
ul.sections {
|
||||
list-style: none;
|
||||
padding:0 0 5px 0;;
|
||||
margin:0;
|
||||
}
|
||||
|
||||
/*
|
||||
Force border-box so that % widths fit the parent
|
||||
container without overlap because of margin/padding.
|
||||
|
||||
More Info : http://www.quirksmode.org/css/box.html
|
||||
*/
|
||||
ul.sections > li > div {
|
||||
-moz-box-sizing: border-box; /* firefox */
|
||||
-ms-box-sizing: border-box; /* ie */
|
||||
-webkit-box-sizing: border-box; /* webkit */
|
||||
-khtml-box-sizing: border-box; /* konqueror */
|
||||
box-sizing: border-box; /* css3 */
|
||||
}
|
||||
|
||||
|
||||
/*---------------------- Jump Page -----------------------------*/
|
||||
#jump_to, #jump_page {
|
||||
margin: 0;
|
||||
background: white;
|
||||
-webkit-box-shadow: 0 0 25px #777; -moz-box-shadow: 0 0 25px #777;
|
||||
-webkit-border-bottom-left-radius: 5px; -moz-border-radius-bottomleft: 5px;
|
||||
font: 16px Arial;
|
||||
cursor: pointer;
|
||||
text-align: right;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
#jump_to a {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
#jump_to a.large {
|
||||
display: none;
|
||||
}
|
||||
#jump_to a.small {
|
||||
font-size: 22px;
|
||||
font-weight: bold;
|
||||
color: #676767;
|
||||
}
|
||||
|
||||
#jump_to, #jump_wrapper {
|
||||
position: fixed;
|
||||
right: 0; top: 0;
|
||||
padding: 10px 15px;
|
||||
margin:0;
|
||||
}
|
||||
|
||||
#jump_wrapper {
|
||||
display: none;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
#jump_to:hover #jump_wrapper {
|
||||
display: block;
|
||||
}
|
||||
|
||||
#jump_page_wrapper{
|
||||
position: fixed;
|
||||
right: 0;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
}
|
||||
|
||||
#jump_page {
|
||||
padding: 5px 0 3px;
|
||||
margin: 0 0 25px 25px;
|
||||
max-height: 100%;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
#jump_page .source {
|
||||
display: block;
|
||||
padding: 15px;
|
||||
text-decoration: none;
|
||||
border-top: 1px solid #eee;
|
||||
}
|
||||
|
||||
#jump_page .source:hover {
|
||||
background: #f5f5ff;
|
||||
}
|
||||
|
||||
#jump_page .source:first-child {
|
||||
}
|
||||
|
||||
/*---------------------- Low resolutions (> 320px) ---------------------*/
|
||||
@media only screen and (min-width: 320px) {
|
||||
.pilwrap { display: none; }
|
||||
|
||||
ul.sections > li > div {
|
||||
display: block;
|
||||
padding:5px 10px 0 10px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation ul, ul.sections > li > div.annotation ol {
|
||||
padding-left: 30px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.content {
|
||||
overflow-x:auto;
|
||||
-webkit-box-shadow: inset 0 0 5px #e5e5ee;
|
||||
box-shadow: inset 0 0 5px #e5e5ee;
|
||||
border: 1px solid #dedede;
|
||||
margin:5px 10px 5px 10px;
|
||||
padding-bottom: 5px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation pre {
|
||||
margin: 7px 0 7px;
|
||||
padding-left: 15px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation p tt, .annotation code {
|
||||
background: #f8f8ff;
|
||||
border: 1px solid #dedede;
|
||||
font-size: 12px;
|
||||
padding: 0 0.2em;
|
||||
}
|
||||
}
|
||||
|
||||
/*---------------------- (> 481px) ---------------------*/
|
||||
@media only screen and (min-width: 481px) {
|
||||
#container {
|
||||
position: relative;
|
||||
}
|
||||
body {
|
||||
background-color: #F5F5FF;
|
||||
font-size: 15px;
|
||||
line-height: 21px;
|
||||
}
|
||||
pre, tt, code {
|
||||
line-height: 18px;
|
||||
}
|
||||
p, ul, ol {
|
||||
margin: 0 0 15px;
|
||||
}
|
||||
|
||||
|
||||
#jump_to {
|
||||
padding: 5px 10px;
|
||||
}
|
||||
#jump_wrapper {
|
||||
padding: 0;
|
||||
}
|
||||
#jump_to, #jump_page {
|
||||
font: 10px Arial;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
#jump_page .source {
|
||||
padding: 5px 10px;
|
||||
}
|
||||
#jump_to a.large {
|
||||
display: inline-block;
|
||||
}
|
||||
#jump_to a.small {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#background {
|
||||
position: absolute;
|
||||
top: 0; bottom: 0;
|
||||
width: 350px;
|
||||
background: #fff;
|
||||
border-right: 1px solid #e5e5ee;
|
||||
z-index: -1;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation ul, ul.sections > li > div.annotation ol {
|
||||
padding-left: 40px;
|
||||
}
|
||||
|
||||
ul.sections > li {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
ul.sections > li > div {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation {
|
||||
max-width: 350px;
|
||||
min-width: 350px;
|
||||
min-height: 5px;
|
||||
padding: 13px;
|
||||
overflow-x: hidden;
|
||||
white-space: normal;
|
||||
vertical-align: top;
|
||||
text-align: left;
|
||||
}
|
||||
ul.sections > li > div.annotation pre {
|
||||
margin: 15px 0 15px;
|
||||
padding-left: 15px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.content {
|
||||
padding: 13px;
|
||||
vertical-align: top;
|
||||
border: none;
|
||||
-webkit-box-shadow: none;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.pilwrap {
|
||||
position: relative;
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.pilcrow {
|
||||
font: 12px Arial;
|
||||
text-decoration: none;
|
||||
color: #454545;
|
||||
position: absolute;
|
||||
top: 3px; left: -20px;
|
||||
padding: 1px 2px;
|
||||
opacity: 0;
|
||||
-webkit-transition: opacity 0.2s linear;
|
||||
}
|
||||
.for-h1 .pilcrow {
|
||||
top: 47px;
|
||||
}
|
||||
.for-h2 .pilcrow, .for-h3 .pilcrow, .for-h4 .pilcrow {
|
||||
top: 35px;
|
||||
}
|
||||
|
||||
ul.sections > li > div.annotation:hover .pilcrow {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
/*---------------------- (> 1025px) ---------------------*/
|
||||
@media only screen and (min-width: 1025px) {
|
||||
|
||||
body {
|
||||
font-size: 16px;
|
||||
line-height: 24px;
|
||||
}
|
||||
|
||||
#background {
|
||||
width: 525px;
|
||||
}
|
||||
ul.sections > li > div.annotation {
|
||||
max-width: 525px;
|
||||
min-width: 525px;
|
||||
padding: 10px 25px 1px 50px;
|
||||
}
|
||||
ul.sections > li > div.content {
|
||||
padding: 9px 15px 16px 25px;
|
||||
}
|
||||
}
|
||||
|
||||
/*---------------------- Syntax Highlighting -----------------------------*/
|
||||
|
||||
td.linenos { background-color: #f0f0f0; padding-right: 10px; }
|
||||
span.lineno { background-color: #f0f0f0; padding: 0 5px 0 5px; }
|
||||
/*
|
||||
|
||||
github.com style (c) Vasily Polovnyov <vast@whiteants.net>
|
||||
|
||||
*/
|
||||
|
||||
pre code {
|
||||
display: block; padding: 0.5em;
|
||||
color: #000;
|
||||
background: #f8f8ff
|
||||
}
|
||||
|
||||
pre .hljs-comment,
|
||||
pre .hljs-template_comment,
|
||||
pre .hljs-diff .hljs-header,
|
||||
pre .hljs-javadoc {
|
||||
color: #408080;
|
||||
font-style: italic
|
||||
}
|
||||
|
||||
pre .hljs-keyword,
|
||||
pre .hljs-assignment,
|
||||
pre .hljs-literal,
|
||||
pre .hljs-css .hljs-rule .hljs-keyword,
|
||||
pre .hljs-winutils,
|
||||
pre .hljs-javascript .hljs-title,
|
||||
pre .hljs-lisp .hljs-title,
|
||||
pre .hljs-subst {
|
||||
color: #954121;
|
||||
/*font-weight: bold*/
|
||||
}
|
||||
|
||||
pre .hljs-number,
|
||||
pre .hljs-hexcolor {
|
||||
color: #40a070
|
||||
}
|
||||
|
||||
pre .hljs-string,
|
||||
pre .hljs-tag .hljs-value,
|
||||
pre .hljs-phpdoc,
|
||||
pre .hljs-tex .hljs-formula {
|
||||
color: #219161;
|
||||
}
|
||||
|
||||
pre .hljs-title,
|
||||
pre .hljs-id {
|
||||
color: #19469D;
|
||||
}
|
||||
pre .hljs-params {
|
||||
color: #00F;
|
||||
}
|
||||
|
||||
pre .hljs-javascript .hljs-title,
|
||||
pre .hljs-lisp .hljs-title,
|
||||
pre .hljs-subst {
|
||||
font-weight: normal
|
||||
}
|
||||
|
||||
pre .hljs-class .hljs-title,
|
||||
pre .hljs-haskell .hljs-label,
|
||||
pre .hljs-tex .hljs-command {
|
||||
color: #458;
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
pre .hljs-tag,
|
||||
pre .hljs-tag .hljs-title,
|
||||
pre .hljs-rules .hljs-property,
|
||||
pre .hljs-django .hljs-tag .hljs-keyword {
|
||||
color: #000080;
|
||||
font-weight: normal
|
||||
}
|
||||
|
||||
pre .hljs-attribute,
|
||||
pre .hljs-variable,
|
||||
pre .hljs-instancevar,
|
||||
pre .hljs-lisp .hljs-body {
|
||||
color: #008080
|
||||
}
|
||||
|
||||
pre .hljs-regexp {
|
||||
color: #B68
|
||||
}
|
||||
|
||||
pre .hljs-class {
|
||||
color: #458;
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
pre .hljs-symbol,
|
||||
pre .hljs-ruby .hljs-symbol .hljs-string,
|
||||
pre .hljs-ruby .hljs-symbol .hljs-keyword,
|
||||
pre .hljs-ruby .hljs-symbol .hljs-keymethods,
|
||||
pre .hljs-lisp .hljs-keyword,
|
||||
pre .hljs-tex .hljs-special,
|
||||
pre .hljs-input_number {
|
||||
color: #990073
|
||||
}
|
||||
|
||||
pre .hljs-builtin,
|
||||
pre .hljs-constructor,
|
||||
pre .hljs-built_in,
|
||||
pre .hljs-lisp .hljs-title {
|
||||
color: #0086b3
|
||||
}
|
||||
|
||||
pre .hljs-preprocessor,
|
||||
pre .hljs-pi,
|
||||
pre .hljs-doctype,
|
||||
pre .hljs-shebang,
|
||||
pre .hljs-cdata {
|
||||
color: #999;
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
pre .hljs-deletion {
|
||||
background: #fdd
|
||||
}
|
||||
|
||||
pre .hljs-addition {
|
||||
background: #dfd
|
||||
}
|
||||
|
||||
pre .hljs-diff .hljs-change {
|
||||
background: #0086b3
|
||||
}
|
||||
|
||||
pre .hljs-chunk {
|
||||
color: #aaa
|
||||
}
|
||||
|
||||
pre .hljs-tex .hljs-formula {
|
||||
opacity: 0.5;
|
||||
}
|
||||
1742
docs/v2/annotated-source/grammar.html
Normal file
630
docs/v2/annotated-source/helpers.html
Normal file
@@ -0,0 +1,630 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>helpers.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>helpers.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>This file contains the common helper functions that we’d like to share among
|
||||
the <strong>Lexer</strong>, <strong>Rewriter</strong>, and the <strong>Nodes</strong>. Merge objects, flatten
|
||||
arrays, count characters, that sort of thing.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>
|
||||
md = <span class="hljs-built_in">require</span>(<span class="hljs-string">'markdown-it'</span>)()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Peek at the beginning of a given string to see if it matches a sequence.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.starts = <span class="hljs-function"><span class="hljs-params">(string, literal, start)</span> -></span>
|
||||
literal <span class="hljs-keyword">is</span> string.substr start, literal.length</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Peek at the end of a given string to see if it matches a sequence.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.ends = <span class="hljs-function"><span class="hljs-params">(string, literal, back)</span> -></span>
|
||||
len = literal.length
|
||||
literal <span class="hljs-keyword">is</span> string.substr string.length - len - (back <span class="hljs-keyword">or</span> <span class="hljs-number">0</span>), len</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Repeat a string <code>n</code> times.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.repeat = repeat = <span class="hljs-function"><span class="hljs-params">(str, n)</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Use clever algorithm to have O(log(n)) string concatenation operations.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> res = <span class="hljs-string">''</span>
|
||||
<span class="hljs-keyword">while</span> n > <span class="hljs-number">0</span>
|
||||
res += str <span class="hljs-keyword">if</span> n & <span class="hljs-number">1</span>
|
||||
n >>>= <span class="hljs-number">1</span>
|
||||
str += str
|
||||
res</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Trim out all falsy values from an array.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.compact = <span class="hljs-function"><span class="hljs-params">(array)</span> -></span>
|
||||
item <span class="hljs-keyword">for</span> item <span class="hljs-keyword">in</span> array <span class="hljs-keyword">when</span> item</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Count the number of occurrences of a string in a string.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.count = <span class="hljs-function"><span class="hljs-params">(string, substr)</span> -></span>
|
||||
num = pos = <span class="hljs-number">0</span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-number">1</span>/<span class="hljs-number">0</span> <span class="hljs-keyword">unless</span> substr.length
|
||||
num++ <span class="hljs-keyword">while</span> pos = <span class="hljs-number">1</span> + string.indexOf substr, pos
|
||||
num</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Merge objects, returning a fresh copy with attributes from both sides.
|
||||
Used every time <code>Base#compile</code> is called, to allow properties in the
|
||||
options hash to propagate down the tree without polluting other branches.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.merge = <span class="hljs-function"><span class="hljs-params">(options, overrides)</span> -></span>
|
||||
extend (extend {}, options), overrides</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Extend a source object with the properties of another object (shallow copy).</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>extend = exports.extend = <span class="hljs-function"><span class="hljs-params">(object, properties)</span> -></span>
|
||||
<span class="hljs-keyword">for</span> key, val <span class="hljs-keyword">of</span> properties
|
||||
object[key] = val
|
||||
object</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Return a flattened version of an array.
|
||||
Handy for getting a list of <code>children</code> from the nodes.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.flatten = flatten = <span class="hljs-function"><span class="hljs-params">(array)</span> -></span>
|
||||
flattened = []
|
||||
<span class="hljs-keyword">for</span> element <span class="hljs-keyword">in</span> array
|
||||
<span class="hljs-keyword">if</span> <span class="hljs-string">'[object Array]'</span> <span class="hljs-keyword">is</span> Object::toString.call element
|
||||
flattened = flattened.concat flatten element
|
||||
<span class="hljs-keyword">else</span>
|
||||
flattened.push element
|
||||
flattened</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Delete a key from an object, returning the value. Useful when a node is
|
||||
looking for a particular method in an options hash.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.del = <span class="hljs-function"><span class="hljs-params">(obj, key)</span> -></span>
|
||||
val = obj[key]
|
||||
<span class="hljs-keyword">delete</span> obj[key]
|
||||
val</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Typical Array::some</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.some = Array::some ? (fn) ->
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-literal">true</span> <span class="hljs-keyword">for</span> e <span class="hljs-keyword">in</span> <span class="hljs-keyword">this</span> <span class="hljs-keyword">when</span> fn e
|
||||
<span class="hljs-literal">false</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Simple function for extracting code from Literate CoffeeScript by stripping
|
||||
out all non-code blocks, producing a string of CoffeeScript code that can
|
||||
be compiled “normally.” Uses <a href="https://markdown-it.github.io/">MarkdownIt</a>
|
||||
to tell the difference between Markdown and code blocks.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.invertLiterate = <span class="hljs-function"><span class="hljs-params">(code)</span> -></span>
|
||||
out = []
|
||||
md.renderer.rules =</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Delete all other rules, since all we want are the code blocks.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> code_block: <span class="hljs-function"><span class="hljs-params">(tokens, idx, options, env, slf)</span> -></span>
|
||||
startLine = tokens[idx].map[<span class="hljs-number">0</span>]
|
||||
lines = tokens[idx].content.split <span class="hljs-string">'\n'</span>
|
||||
<span class="hljs-keyword">for</span> line, i <span class="hljs-keyword">in</span> lines
|
||||
out[startLine + i] = line
|
||||
md.render code
|
||||
out.join <span class="hljs-string">'\n'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>Merge two jison-style location data objects together.
|
||||
If <code>last</code> is not provided, this will simply return <code>first</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">buildLocationData</span> = <span class="hljs-params">(first, last)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> last
|
||||
first
|
||||
<span class="hljs-keyword">else</span>
|
||||
first_line: first.first_line
|
||||
first_column: first.first_column
|
||||
last_line: last.last_line
|
||||
last_column: last.last_column</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>This returns a function which takes an object as a parameter, and if that
|
||||
object is an AST node, updates that object’s locationData.
|
||||
The object is returned either way.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.addLocationDataFn = <span class="hljs-function"><span class="hljs-params">(first, last)</span> -></span>
|
||||
(obj) ->
|
||||
<span class="hljs-keyword">if</span> ((<span class="hljs-keyword">typeof</span> obj) <span class="hljs-keyword">is</span> <span class="hljs-string">'object'</span>) <span class="hljs-keyword">and</span> (!!obj[<span class="hljs-string">'updateLocationDataIfMissing'</span>])
|
||||
obj.updateLocationDataIfMissing buildLocationData(first, last)
|
||||
|
||||
<span class="hljs-keyword">return</span> obj</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>Convert jison location data to a string.
|
||||
<code>obj</code> can be a token, or a locationData.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.locationDataToString = <span class="hljs-function"><span class="hljs-params">(obj)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> (<span class="hljs-string">"2"</span> <span class="hljs-keyword">of</span> obj) <span class="hljs-keyword">and</span> (<span class="hljs-string">"first_line"</span> <span class="hljs-keyword">of</span> obj[<span class="hljs-number">2</span>]) <span class="hljs-keyword">then</span> locationData = obj[<span class="hljs-number">2</span>]
|
||||
<span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span> <span class="hljs-string">"first_line"</span> <span class="hljs-keyword">of</span> obj <span class="hljs-keyword">then</span> locationData = obj
|
||||
|
||||
<span class="hljs-keyword">if</span> locationData
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{locationData.first_line + <span class="hljs-number">1</span>}</span>:<span class="hljs-subst">#{locationData.first_column + <span class="hljs-number">1</span>}</span>-"</span> +
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{locationData.last_line + <span class="hljs-number">1</span>}</span>:<span class="hljs-subst">#{locationData.last_column + <span class="hljs-number">1</span>}</span>"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">"No location data"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>A <code>.coffee.md</code> compatible version of <code>basename</code>, that returns the file sans-extension.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.baseFileName = <span class="hljs-function"><span class="hljs-params">(file, stripExt = <span class="hljs-literal">no</span>, useWinPathSep = <span class="hljs-literal">no</span>)</span> -></span>
|
||||
pathSep = <span class="hljs-keyword">if</span> useWinPathSep <span class="hljs-keyword">then</span> <span class="hljs-regexp">/\\|\//</span> <span class="hljs-keyword">else</span> <span class="hljs-regexp">/\//</span>
|
||||
parts = file.split(pathSep)
|
||||
file = parts[parts.length - <span class="hljs-number">1</span>]
|
||||
<span class="hljs-keyword">return</span> file <span class="hljs-keyword">unless</span> stripExt <span class="hljs-keyword">and</span> file.indexOf(<span class="hljs-string">'.'</span>) >= <span class="hljs-number">0</span>
|
||||
parts = file.split(<span class="hljs-string">'.'</span>)
|
||||
parts.pop()
|
||||
parts.pop() <span class="hljs-keyword">if</span> parts[parts.length - <span class="hljs-number">1</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">'coffee'</span> <span class="hljs-keyword">and</span> parts.length > <span class="hljs-number">1</span>
|
||||
parts.join(<span class="hljs-string">'.'</span>)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Determine if a filename represents a CoffeeScript file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.isCoffee = <span class="hljs-function"><span class="hljs-params">(file)</span> -></span> <span class="hljs-regexp">/\.((lit)?coffee|coffee\.md)$/</span>.test file</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<p>Determine if a filename represents a Literate CoffeeScript file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.isLiterate = <span class="hljs-function"><span class="hljs-params">(file)</span> -></span> <span class="hljs-regexp">/\.(litcoffee|coffee\.md)$/</span>.test file</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
<p>Throws a SyntaxError from a given location.
|
||||
The error’s <code>toString</code> will return an error message following the “standard”
|
||||
format <code><filename>:<line>:<col>: <message></code> plus the line with the error and a
|
||||
marker showing where the error is.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.throwSyntaxError = <span class="hljs-function"><span class="hljs-params">(message, location)</span> -></span>
|
||||
error = <span class="hljs-keyword">new</span> SyntaxError message
|
||||
error.location = location
|
||||
error.toString = syntaxErrorToString</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>Instead of showing the compiler’s stacktrace, show our custom error message
|
||||
(this is useful when the error bubbles up in Node.js applications that
|
||||
compile CoffeeScript for example).</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> error.stack = error.toString()
|
||||
|
||||
<span class="hljs-keyword">throw</span> error</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-23">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-23">¶</a>
|
||||
</div>
|
||||
<p>Update a compiler SyntaxError with source code information if it didn’t have
|
||||
it already.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.updateSyntaxError = <span class="hljs-function"><span class="hljs-params">(error, code, filename)</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-24">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-24">¶</a>
|
||||
</div>
|
||||
<p>Avoid screwing up the <code>stack</code> property of other errors (i.e. possible bugs).</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> error.toString <span class="hljs-keyword">is</span> syntaxErrorToString
|
||||
error.code <span class="hljs-keyword">or</span>= code
|
||||
error.filename <span class="hljs-keyword">or</span>= filename
|
||||
error.stack = error.toString()
|
||||
error
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">syntaxErrorToString</span> = -></span>
|
||||
<span class="hljs-keyword">return</span> Error::toString.call @ <span class="hljs-keyword">unless</span> @code <span class="hljs-keyword">and</span> @location
|
||||
|
||||
{first_line, first_column, last_line, last_column} = @location
|
||||
last_line ?= first_line
|
||||
last_column ?= first_column
|
||||
|
||||
filename = @filename <span class="hljs-keyword">or</span> <span class="hljs-string">'[stdin]'</span>
|
||||
codeLine = @code.split(<span class="hljs-string">'\n'</span>)[first_line]
|
||||
start = first_column</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-25">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-25">¶</a>
|
||||
</div>
|
||||
<p>Show only the first line on multi-line errors.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> end = <span class="hljs-keyword">if</span> first_line <span class="hljs-keyword">is</span> last_line <span class="hljs-keyword">then</span> last_column + <span class="hljs-number">1</span> <span class="hljs-keyword">else</span> codeLine.length
|
||||
marker = codeLine[...start].replace(<span class="hljs-regexp">/[^\s]/g</span>, <span class="hljs-string">' '</span>) + repeat(<span class="hljs-string">'^'</span>, end - start)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-26">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-26">¶</a>
|
||||
</div>
|
||||
<p>Check to see if we’re running on a color-enabled TTY.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> process?
|
||||
colorsEnabled = process.stdout?.isTTY <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> process.env?.NODE_DISABLE_COLORS
|
||||
|
||||
<span class="hljs-keyword">if</span> @colorful ? colorsEnabled
|
||||
<span class="hljs-function"> <span class="hljs-title">colorize</span> = <span class="hljs-params">(str)</span> -></span> <span class="hljs-string">"\x1B[1;31m<span class="hljs-subst">#{str}</span>\x1B[0m"</span>
|
||||
codeLine = codeLine[...start] + colorize(codeLine[start...end]) + codeLine[end..]
|
||||
marker = colorize marker
|
||||
|
||||
<span class="hljs-string">"""
|
||||
<span class="hljs-subst">#{filename}</span>:<span class="hljs-subst">#{first_line + <span class="hljs-number">1</span>}</span>:<span class="hljs-subst">#{first_column + <span class="hljs-number">1</span>}</span>: error: <span class="hljs-subst">#{@message}</span>
|
||||
<span class="hljs-subst">#{codeLine}</span>
|
||||
<span class="hljs-subst">#{marker}</span>
|
||||
"""</span>
|
||||
|
||||
exports.nameWhitespaceCharacter = <span class="hljs-function"><span class="hljs-params">(string)</span> -></span>
|
||||
<span class="hljs-keyword">switch</span> string
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-string">' '</span> <span class="hljs-keyword">then</span> <span class="hljs-string">'space'</span>
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-string">'\n'</span> <span class="hljs-keyword">then</span> <span class="hljs-string">'newline'</span>
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-string">'\r'</span> <span class="hljs-keyword">then</span> <span class="hljs-string">'carriage return'</span>
|
||||
<span class="hljs-keyword">when</span> <span class="hljs-string">'\t'</span> <span class="hljs-keyword">then</span> <span class="hljs-string">'tab'</span>
|
||||
<span class="hljs-keyword">else</span> string</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
129
docs/v2/annotated-source/index.html
Normal file
@@ -0,0 +1,129 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>index.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>index.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>Loader for CoffeeScript as a Node.js library.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports[key] = val <span class="hljs-keyword">for</span> key, val <span class="hljs-keyword">of</span> <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffeescript'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
2311
docs/v2/annotated-source/lexer.html
Normal file
6245
docs/v2/annotated-source/nodes.html
Normal file
366
docs/v2/annotated-source/optparse.html
Normal file
@@ -0,0 +1,366 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>optparse.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>optparse.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>{repeat} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>A simple <strong>OptionParser</strong> class to parse option flags from the command-line.
|
||||
Use it like so:</p>
|
||||
<pre><code>parser = <span class="hljs-keyword">new</span> OptionParser switches, helpBanner
|
||||
options = parser.parse process.argv
|
||||
</code></pre><p>The first non-option is considered to be the start of the file (and file
|
||||
option) list, and all subsequent arguments are left unparsed.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.OptionParser = <span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">OptionParser</span></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Initialize with a list of valid options, in the form:</p>
|
||||
<pre><code>[short-flag, long-flag, description]
|
||||
</code></pre><p>Along with an optional banner for the usage help.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> constructor: <span class="hljs-function"><span class="hljs-params">(rules, @banner)</span> -></span>
|
||||
@rules = buildRules rules</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Parse the list of arguments, populating an <code>options</code> object with all of the
|
||||
specified options, and return it. Options after the first non-option
|
||||
argument are treated as arguments. <code>options.arguments</code> will be an array
|
||||
containing the remaining arguments. This is a simpler API than many option
|
||||
parsers that allow you to attach callback actions for every flag. Instead,
|
||||
you’re responsible for interpreting the options object.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> parse: <span class="hljs-function"><span class="hljs-params">(args)</span> -></span>
|
||||
options = arguments: []
|
||||
skippingArgument = <span class="hljs-literal">no</span>
|
||||
originalArgs = args
|
||||
args = normalizeArguments args
|
||||
<span class="hljs-keyword">for</span> arg, i <span class="hljs-keyword">in</span> args
|
||||
<span class="hljs-keyword">if</span> skippingArgument
|
||||
skippingArgument = <span class="hljs-literal">no</span>
|
||||
<span class="hljs-keyword">continue</span>
|
||||
<span class="hljs-keyword">if</span> arg <span class="hljs-keyword">is</span> <span class="hljs-string">'--'</span>
|
||||
pos = originalArgs.indexOf <span class="hljs-string">'--'</span>
|
||||
options.arguments = options.arguments.concat originalArgs[(pos + <span class="hljs-number">1</span>)..]
|
||||
<span class="hljs-keyword">break</span>
|
||||
isOption = !!(arg.match(LONG_FLAG) <span class="hljs-keyword">or</span> arg.match(SHORT_FLAG))</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>the CS option parser is a little odd; options after the first
|
||||
non-option argument are treated as non-option arguments themselves</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> seenNonOptionArg = options.arguments.length > <span class="hljs-number">0</span>
|
||||
<span class="hljs-keyword">unless</span> seenNonOptionArg
|
||||
matchedRule = <span class="hljs-literal">no</span>
|
||||
<span class="hljs-keyword">for</span> rule <span class="hljs-keyword">in</span> @rules
|
||||
<span class="hljs-keyword">if</span> rule.shortFlag <span class="hljs-keyword">is</span> arg <span class="hljs-keyword">or</span> rule.longFlag <span class="hljs-keyword">is</span> arg
|
||||
value = <span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">if</span> rule.hasArgument
|
||||
skippingArgument = <span class="hljs-literal">yes</span>
|
||||
value = args[i + <span class="hljs-number">1</span>]
|
||||
options[rule.name] = <span class="hljs-keyword">if</span> rule.isList <span class="hljs-keyword">then</span> (options[rule.name] <span class="hljs-keyword">or</span> []).concat value <span class="hljs-keyword">else</span> value
|
||||
matchedRule = <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-keyword">break</span>
|
||||
<span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"unrecognized option: <span class="hljs-subst">#{arg}</span>"</span> <span class="hljs-keyword">if</span> isOption <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> matchedRule
|
||||
<span class="hljs-keyword">if</span> seenNonOptionArg <span class="hljs-keyword">or</span> <span class="hljs-keyword">not</span> isOption
|
||||
options.arguments.push arg
|
||||
options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Return the help text for this <strong>OptionParser</strong>, listing and describing all
|
||||
of the valid options, for <code>--help</code> and such.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> help: <span class="hljs-function">-></span>
|
||||
lines = []
|
||||
lines.unshift <span class="hljs-string">"<span class="hljs-subst">#{@banner}</span>\n"</span> <span class="hljs-keyword">if</span> @banner
|
||||
<span class="hljs-keyword">for</span> rule <span class="hljs-keyword">in</span> @rules
|
||||
spaces = <span class="hljs-number">15</span> - rule.longFlag.length
|
||||
spaces = <span class="hljs-keyword">if</span> spaces > <span class="hljs-number">0</span> <span class="hljs-keyword">then</span> repeat <span class="hljs-string">' '</span>, spaces <span class="hljs-keyword">else</span> <span class="hljs-string">''</span>
|
||||
letPart = <span class="hljs-keyword">if</span> rule.shortFlag <span class="hljs-keyword">then</span> rule.shortFlag + <span class="hljs-string">', '</span> <span class="hljs-keyword">else</span> <span class="hljs-string">' '</span>
|
||||
lines.push <span class="hljs-string">' '</span> + letPart + rule.longFlag + spaces + rule.description
|
||||
<span class="hljs-string">"\n<span class="hljs-subst">#{ lines.join(<span class="hljs-string">'\n'</span>) }</span>\n"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<h2 id="helpers">Helpers</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Regex matchers for option flags.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>LONG_FLAG = <span class="hljs-regexp">/^(--\w[\w\-]*)/</span>
|
||||
SHORT_FLAG = <span class="hljs-regexp">/^(-\w)$/</span>
|
||||
MULTI_FLAG = <span class="hljs-regexp">/^-(\w{2,})/</span>
|
||||
OPTIONAL = <span class="hljs-regexp">/\[(\w+(\*?))\]/</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Build and return the list of option rules. If the optional <em>short-flag</em> is
|
||||
unspecified, leave it out by padding with <code>null</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">buildRules</span> = <span class="hljs-params">(rules)</span> -></span>
|
||||
<span class="hljs-keyword">for</span> tuple <span class="hljs-keyword">in</span> rules
|
||||
tuple.unshift <span class="hljs-literal">null</span> <span class="hljs-keyword">if</span> tuple.length < <span class="hljs-number">3</span>
|
||||
buildRule tuple...</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Build a rule from a <code>-o</code> short flag, a <code>--output [DIR]</code> long flag, and the
|
||||
description of what the option does.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">buildRule</span> = <span class="hljs-params">(shortFlag, longFlag, description, options = {})</span> -></span>
|
||||
match = longFlag.match(OPTIONAL)
|
||||
longFlag = longFlag.match(LONG_FLAG)[<span class="hljs-number">1</span>]
|
||||
{
|
||||
name: longFlag.substr <span class="hljs-number">2</span>
|
||||
shortFlag: shortFlag
|
||||
longFlag: longFlag
|
||||
description: description
|
||||
hasArgument: !!(match <span class="hljs-keyword">and</span> match[<span class="hljs-number">1</span>])
|
||||
isList: !!(match <span class="hljs-keyword">and</span> match[<span class="hljs-number">2</span>])
|
||||
}</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Normalize arguments by expanding merged flags into multiple flags. This allows
|
||||
you to have <code>-wl</code> be the same as <code>--watch --lint</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">normalizeArguments</span> = <span class="hljs-params">(args)</span> -></span>
|
||||
args = args[..]
|
||||
result = []
|
||||
<span class="hljs-keyword">for</span> arg <span class="hljs-keyword">in</span> args
|
||||
<span class="hljs-keyword">if</span> match = arg.match MULTI_FLAG
|
||||
result.push <span class="hljs-string">'-'</span> + l <span class="hljs-keyword">for</span> l <span class="hljs-keyword">in</span> match[<span class="hljs-number">1</span>].split <span class="hljs-string">''</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
result.push arg
|
||||
result</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
BIN
docs/v2/annotated-source/public/fonts/aller-bold.eot
Normal file
BIN
docs/v2/annotated-source/public/fonts/aller-bold.ttf
Normal file
BIN
docs/v2/annotated-source/public/fonts/aller-bold.woff
Normal file
BIN
docs/v2/annotated-source/public/fonts/aller-light.eot
Normal file
BIN
docs/v2/annotated-source/public/fonts/aller-light.ttf
Normal file
BIN
docs/v2/annotated-source/public/fonts/aller-light.woff
Normal file
BIN
docs/v2/annotated-source/public/fonts/roboto-black.eot
Executable file
BIN
docs/v2/annotated-source/public/fonts/roboto-black.ttf
Executable file
BIN
docs/v2/annotated-source/public/fonts/roboto-black.woff
Executable file
375
docs/v2/annotated-source/public/stylesheets/normalize.css
vendored
Normal file
@@ -0,0 +1,375 @@
|
||||
/*! normalize.css v2.0.1 | MIT License | git.io/normalize */
|
||||
|
||||
/* ==========================================================================
|
||||
HTML5 display definitions
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Corrects `block` display not defined in IE 8/9.
|
||||
*/
|
||||
|
||||
article,
|
||||
aside,
|
||||
details,
|
||||
figcaption,
|
||||
figure,
|
||||
footer,
|
||||
header,
|
||||
hgroup,
|
||||
nav,
|
||||
section,
|
||||
summary {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/*
|
||||
* Corrects `inline-block` display not defined in IE 8/9.
|
||||
*/
|
||||
|
||||
audio,
|
||||
canvas,
|
||||
video {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
/*
|
||||
* Prevents modern browsers from displaying `audio` without controls.
|
||||
* Remove excess height in iOS 5 devices.
|
||||
*/
|
||||
|
||||
audio:not([controls]) {
|
||||
display: none;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses styling for `hidden` attribute not present in IE 8/9.
|
||||
*/
|
||||
|
||||
[hidden] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Base
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* 1. Sets default font family to sans-serif.
|
||||
* 2. Prevents iOS text size adjust after orientation change, without disabling
|
||||
* user zoom.
|
||||
*/
|
||||
|
||||
html {
|
||||
font-family: sans-serif; /* 1 */
|
||||
-webkit-text-size-adjust: 100%; /* 2 */
|
||||
-ms-text-size-adjust: 100%; /* 2 */
|
||||
}
|
||||
|
||||
/*
|
||||
* Removes default margin.
|
||||
*/
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Links
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Addresses `outline` inconsistency between Chrome and other browsers.
|
||||
*/
|
||||
|
||||
a:focus {
|
||||
outline: thin dotted;
|
||||
}
|
||||
|
||||
/*
|
||||
* Improves readability when focused and also mouse hovered in all browsers.
|
||||
*/
|
||||
|
||||
a:active,
|
||||
a:hover {
|
||||
outline: 0;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Typography
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Addresses `h1` font sizes within `section` and `article` in Firefox 4+,
|
||||
* Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
h1 {
|
||||
font-size: 2em;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses styling not present in IE 8/9, Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
abbr[title] {
|
||||
border-bottom: 1px dotted;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses style set to `bolder` in Firefox 4+, Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
b,
|
||||
strong {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses styling not present in Safari 5 and Chrome.
|
||||
*/
|
||||
|
||||
dfn {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses styling not present in IE 8/9.
|
||||
*/
|
||||
|
||||
mark {
|
||||
background: #ff0;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Corrects font family set oddly in Safari 5 and Chrome.
|
||||
*/
|
||||
|
||||
code,
|
||||
kbd,
|
||||
pre,
|
||||
samp {
|
||||
font-family: monospace, serif;
|
||||
font-size: 1em;
|
||||
}
|
||||
|
||||
/*
|
||||
* Improves readability of pre-formatted text in all browsers.
|
||||
*/
|
||||
|
||||
pre {
|
||||
white-space: pre;
|
||||
white-space: pre-wrap;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
/*
|
||||
* Sets consistent quote types.
|
||||
*/
|
||||
|
||||
q {
|
||||
quotes: "\201C" "\201D" "\2018" "\2019";
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses inconsistent and variable font size in all browsers.
|
||||
*/
|
||||
|
||||
small {
|
||||
font-size: 80%;
|
||||
}
|
||||
|
||||
/*
|
||||
* Prevents `sub` and `sup` affecting `line-height` in all browsers.
|
||||
*/
|
||||
|
||||
sub,
|
||||
sup {
|
||||
font-size: 75%;
|
||||
line-height: 0;
|
||||
position: relative;
|
||||
vertical-align: baseline;
|
||||
}
|
||||
|
||||
sup {
|
||||
top: -0.5em;
|
||||
}
|
||||
|
||||
sub {
|
||||
bottom: -0.25em;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Embedded content
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Removes border when inside `a` element in IE 8/9.
|
||||
*/
|
||||
|
||||
img {
|
||||
border: 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Corrects overflow displayed oddly in IE 9.
|
||||
*/
|
||||
|
||||
svg:not(:root) {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Figures
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Addresses margin not present in IE 8/9 and Safari 5.
|
||||
*/
|
||||
|
||||
figure {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Forms
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Define consistent border, margin, and padding.
|
||||
*/
|
||||
|
||||
fieldset {
|
||||
border: 1px solid #c0c0c0;
|
||||
margin: 0 2px;
|
||||
padding: 0.35em 0.625em 0.75em;
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Corrects color not being inherited in IE 8/9.
|
||||
* 2. Remove padding so people aren't caught out if they zero out fieldsets.
|
||||
*/
|
||||
|
||||
legend {
|
||||
border: 0; /* 1 */
|
||||
padding: 0; /* 2 */
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Corrects font family not being inherited in all browsers.
|
||||
* 2. Corrects font size not being inherited in all browsers.
|
||||
* 3. Addresses margins set differently in Firefox 4+, Safari 5, and Chrome
|
||||
*/
|
||||
|
||||
button,
|
||||
input,
|
||||
select,
|
||||
textarea {
|
||||
font-family: inherit; /* 1 */
|
||||
font-size: 100%; /* 2 */
|
||||
margin: 0; /* 3 */
|
||||
}
|
||||
|
||||
/*
|
||||
* Addresses Firefox 4+ setting `line-height` on `input` using `!important` in
|
||||
* the UA stylesheet.
|
||||
*/
|
||||
|
||||
button,
|
||||
input {
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
|
||||
* and `video` controls.
|
||||
* 2. Corrects inability to style clickable `input` types in iOS.
|
||||
* 3. Improves usability and consistency of cursor style between image-type
|
||||
* `input` and others.
|
||||
*/
|
||||
|
||||
button,
|
||||
html input[type="button"], /* 1 */
|
||||
input[type="reset"],
|
||||
input[type="submit"] {
|
||||
-webkit-appearance: button; /* 2 */
|
||||
cursor: pointer; /* 3 */
|
||||
}
|
||||
|
||||
/*
|
||||
* Re-set default cursor for disabled elements.
|
||||
*/
|
||||
|
||||
button[disabled],
|
||||
input[disabled] {
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Addresses box sizing set to `content-box` in IE 8/9.
|
||||
* 2. Removes excess padding in IE 8/9.
|
||||
*/
|
||||
|
||||
input[type="checkbox"],
|
||||
input[type="radio"] {
|
||||
box-sizing: border-box; /* 1 */
|
||||
padding: 0; /* 2 */
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Addresses `appearance` set to `searchfield` in Safari 5 and Chrome.
|
||||
* 2. Addresses `box-sizing` set to `border-box` in Safari 5 and Chrome
|
||||
* (include `-moz` to future-proof).
|
||||
*/
|
||||
|
||||
input[type="search"] {
|
||||
-webkit-appearance: textfield; /* 1 */
|
||||
-moz-box-sizing: content-box;
|
||||
-webkit-box-sizing: content-box; /* 2 */
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
/*
|
||||
* Removes inner padding and search cancel button in Safari 5 and Chrome
|
||||
* on OS X.
|
||||
*/
|
||||
|
||||
input[type="search"]::-webkit-search-cancel-button,
|
||||
input[type="search"]::-webkit-search-decoration {
|
||||
-webkit-appearance: none;
|
||||
}
|
||||
|
||||
/*
|
||||
* Removes inner padding and border in Firefox 4+.
|
||||
*/
|
||||
|
||||
button::-moz-focus-inner,
|
||||
input::-moz-focus-inner {
|
||||
border: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* 1. Removes default vertical scrollbar in IE 8/9.
|
||||
* 2. Improves readability and alignment in all browsers.
|
||||
*/
|
||||
|
||||
textarea {
|
||||
overflow: auto; /* 1 */
|
||||
vertical-align: top; /* 2 */
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Tables
|
||||
========================================================================== */
|
||||
|
||||
/*
|
||||
* Remove most spacing between table cells.
|
||||
*/
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
}
|
||||
251
docs/v2/annotated-source/register.html
Normal file
@@ -0,0 +1,251 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>register.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>register.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffeescript'</span>
|
||||
child_process = <span class="hljs-built_in">require</span> <span class="hljs-string">'child_process'</span>
|
||||
helpers = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Load and run a CoffeeScript file for Node, stripping any <code>BOM</code>s.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">loadFile</span> = <span class="hljs-params">(<span class="hljs-built_in">module</span>, filename)</span> -></span>
|
||||
answer = CoffeeScript._compileFile filename, <span class="hljs-literal">no</span>, <span class="hljs-literal">yes</span>
|
||||
<span class="hljs-built_in">module</span>._compile answer, filename</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>If the installed version of Node supports <code>require.extensions</code>, register
|
||||
CoffeeScript as an extension.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> <span class="hljs-built_in">require</span>.extensions
|
||||
<span class="hljs-keyword">for</span> ext <span class="hljs-keyword">in</span> CoffeeScript.FILE_EXTENSIONS
|
||||
<span class="hljs-built_in">require</span>.extensions[ext] = loadFile</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Patch Node’s module loader to be able to handle multi-dot extensions.
|
||||
This is a horrible thing that should not be required.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> Module = <span class="hljs-built_in">require</span> <span class="hljs-string">'module'</span>
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">findExtension</span> = <span class="hljs-params">(filename)</span> -></span>
|
||||
extensions = path.basename(filename).split <span class="hljs-string">'.'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Remove the initial dot from dotfiles.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> extensions.shift() <span class="hljs-keyword">if</span> extensions[<span class="hljs-number">0</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">''</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Start with the longest possible extension and work our way shortwards.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">while</span> extensions.shift()
|
||||
curExtension = <span class="hljs-string">'.'</span> + extensions.join <span class="hljs-string">'.'</span>
|
||||
<span class="hljs-keyword">return</span> curExtension <span class="hljs-keyword">if</span> Module._extensions[curExtension]
|
||||
<span class="hljs-string">'.js'</span>
|
||||
|
||||
Module::load = <span class="hljs-function"><span class="hljs-params">(filename)</span> -></span>
|
||||
@filename = filename
|
||||
@paths = Module._nodeModulePaths path.dirname filename
|
||||
extension = findExtension filename
|
||||
Module._extensions[extension](<span class="hljs-keyword">this</span>, filename)
|
||||
@loaded = <span class="hljs-literal">true</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>If we’re on Node, patch <code>child_process.fork</code> so that Coffee scripts are able
|
||||
to fork both CoffeeScript files, and JavaScript files, directly.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-keyword">if</span> child_process
|
||||
{fork} = child_process
|
||||
binary = <span class="hljs-built_in">require</span>.resolve <span class="hljs-string">'../../bin/coffee'</span>
|
||||
child_process.fork = <span class="hljs-function"><span class="hljs-params">(path, args, options)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> helpers.isCoffee path
|
||||
<span class="hljs-keyword">unless</span> Array.isArray args
|
||||
options = args <span class="hljs-keyword">or</span> {}
|
||||
args = []
|
||||
args = [path].concat args
|
||||
path = binary
|
||||
fork path, args, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
624
docs/v2/annotated-source/repl.html
Normal file
@@ -0,0 +1,624 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>repl.coffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>repl.coffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>fs = <span class="hljs-built_in">require</span> <span class="hljs-string">'fs'</span>
|
||||
path = <span class="hljs-built_in">require</span> <span class="hljs-string">'path'</span>
|
||||
vm = <span class="hljs-built_in">require</span> <span class="hljs-string">'vm'</span>
|
||||
nodeREPL = <span class="hljs-built_in">require</span> <span class="hljs-string">'repl'</span>
|
||||
CoffeeScript = <span class="hljs-built_in">require</span> <span class="hljs-string">'./coffeescript'</span>
|
||||
{merge, updateSyntaxError} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./helpers'</span>
|
||||
|
||||
replDefaults =
|
||||
prompt: <span class="hljs-string">'coffee> '</span>,
|
||||
historyFile: path.join process.env.HOME, <span class="hljs-string">'.coffee_history'</span> <span class="hljs-keyword">if</span> process.env.HOME
|
||||
historyMaxInputSize: <span class="hljs-number">10240</span>
|
||||
eval: <span class="hljs-function"><span class="hljs-params">(input, context, filename, cb)</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>XXX: multiline hack.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> input = input.replace <span class="hljs-regexp">/\uFF00/g</span>, <span class="hljs-string">'\n'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>Node’s REPL sends the input ending with a newline and then wrapped in
|
||||
parens. Unwrap all that.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> input = input.replace <span class="hljs-regexp">/^\(([\s\S]*)\n\)$/m</span>, <span class="hljs-string">'$1'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Node’s REPL v6.9.1+ sends the input wrapped in a try/catch statement.
|
||||
Unwrap that too.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> input = input.replace <span class="hljs-regexp">/^\s*try\s*{([\s\S]*)}\s*catch.*$/m</span>, <span class="hljs-string">'$1'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Require AST nodes to do some AST manipulation.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> {Block, Assign, Value, Literal} = <span class="hljs-built_in">require</span> <span class="hljs-string">'./nodes'</span>
|
||||
|
||||
<span class="hljs-keyword">try</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Tokenize the clean input.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> tokens = CoffeeScript.tokens input</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Collect referenced variable names just like in <code>CoffeeScript.compile</code>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> referencedVars = (
|
||||
token[<span class="hljs-number">1</span>] <span class="hljs-keyword">for</span> token <span class="hljs-keyword">in</span> tokens <span class="hljs-keyword">when</span> token[<span class="hljs-number">0</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">'IDENTIFIER'</span>
|
||||
)</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Generate the AST of the tokens.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> ast = CoffeeScript.nodes tokens</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Add assignment to <code>_</code> variable to force the input to be an expression.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> ast = <span class="hljs-keyword">new</span> Block [
|
||||
<span class="hljs-keyword">new</span> Assign (<span class="hljs-keyword">new</span> Value <span class="hljs-keyword">new</span> Literal <span class="hljs-string">'_'</span>), ast, <span class="hljs-string">'='</span>
|
||||
]
|
||||
js = ast.compile {bare: <span class="hljs-literal">yes</span>, locals: Object.keys(context), referencedVars}
|
||||
cb <span class="hljs-literal">null</span>, runInContext js, context, filename
|
||||
<span class="hljs-keyword">catch</span> err</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>AST’s <code>compile</code> does not add source code information to syntax errors.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> updateSyntaxError err, input
|
||||
cb err
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">runInContext</span> = <span class="hljs-params">(js, context, filename)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> context <span class="hljs-keyword">is</span> <span class="hljs-built_in">global</span>
|
||||
vm.runInThisContext js, filename
|
||||
<span class="hljs-keyword">else</span>
|
||||
vm.runInContext js, context, filename
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">addMultilineHandler</span> = <span class="hljs-params">(repl)</span> -></span>
|
||||
{rli, inputStream, outputStream} = repl</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>Node 0.11.12 changed API, prompt is now _prompt.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> origPrompt = repl._prompt ? repl.prompt
|
||||
|
||||
multiline =
|
||||
enabled: <span class="hljs-literal">off</span>
|
||||
initialPrompt: origPrompt.replace <span class="hljs-regexp">/^[^> ]*/</span>, <span class="hljs-function"><span class="hljs-params">(x)</span> -></span> x.replace <span class="hljs-regexp">/./g</span>, <span class="hljs-string">'-'</span>
|
||||
prompt: origPrompt.replace <span class="hljs-regexp">/^[^> ]*>?/</span>, <span class="hljs-function"><span class="hljs-params">(x)</span> -></span> x.replace <span class="hljs-regexp">/./g</span>, <span class="hljs-string">'.'</span>
|
||||
buffer: <span class="hljs-string">''</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Proxy node’s line listener</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> nodeLineListener = rli.listeners(<span class="hljs-string">'line'</span>)[<span class="hljs-number">0</span>]
|
||||
rli.removeListener <span class="hljs-string">'line'</span>, nodeLineListener
|
||||
rli.<span class="hljs-literal">on</span> <span class="hljs-string">'line'</span>, <span class="hljs-function"><span class="hljs-params">(cmd)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> multiline.enabled
|
||||
multiline.buffer += <span class="hljs-string">"<span class="hljs-subst">#{cmd}</span>\n"</span>
|
||||
rli.setPrompt multiline.prompt
|
||||
rli.prompt <span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
rli.setPrompt origPrompt
|
||||
nodeLineListener cmd
|
||||
<span class="hljs-keyword">return</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Handle Ctrl-v</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> inputStream.<span class="hljs-literal">on</span> <span class="hljs-string">'keypress'</span>, <span class="hljs-function"><span class="hljs-params">(char, key)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">unless</span> key <span class="hljs-keyword">and</span> key.ctrl <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> key.meta <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> key.shift <span class="hljs-keyword">and</span> key.name <span class="hljs-keyword">is</span> <span class="hljs-string">'v'</span>
|
||||
<span class="hljs-keyword">if</span> multiline.enabled</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>allow arbitrarily switching between modes any time before multiple lines are entered</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">unless</span> multiline.buffer.match <span class="hljs-regexp">/\n/</span>
|
||||
multiline.enabled = <span class="hljs-keyword">not</span> multiline.enabled
|
||||
rli.setPrompt origPrompt
|
||||
rli.prompt <span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">return</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>no-op unless the current line is empty</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> rli.line? <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> rli.line.match <span class="hljs-regexp">/^\s*$/</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>eval, print, loop</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> multiline.enabled = <span class="hljs-keyword">not</span> multiline.enabled
|
||||
rli.line = <span class="hljs-string">''</span>
|
||||
rli.cursor = <span class="hljs-number">0</span>
|
||||
rli.output.cursorTo <span class="hljs-number">0</span>
|
||||
rli.output.clearLine <span class="hljs-number">1</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>XXX: multiline hack</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> multiline.buffer = multiline.buffer.replace <span class="hljs-regexp">/\n/g</span>, <span class="hljs-string">'\uFF00'</span>
|
||||
rli.emit <span class="hljs-string">'line'</span>, multiline.buffer
|
||||
multiline.buffer = <span class="hljs-string">''</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
multiline.enabled = <span class="hljs-keyword">not</span> multiline.enabled
|
||||
rli.setPrompt multiline.initialPrompt
|
||||
rli.prompt <span class="hljs-literal">true</span>
|
||||
<span class="hljs-keyword">return</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>Store and load command history from a file</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-function"><span class="hljs-title">addHistory</span> = <span class="hljs-params">(repl, filename, maxSize)</span> -></span>
|
||||
lastLine = <span class="hljs-literal">null</span>
|
||||
<span class="hljs-keyword">try</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Get file info and at most maxSize of command history</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> stat = fs.statSync filename
|
||||
size = Math.min maxSize, stat.size</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<p>Read last <code>size</code> bytes from the file</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> readFd = fs.openSync filename, <span class="hljs-string">'r'</span>
|
||||
buffer = Buffer.alloc size
|
||||
fs.readSync readFd, buffer, <span class="hljs-number">0</span>, size, stat.size - size
|
||||
fs.closeSync readFd</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
<p>Set the history on the interpreter</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.rli.history = buffer.toString().split(<span class="hljs-string">'\n'</span>).reverse()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>If the history file was truncated we should pop off a potential partial line</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.rli.history.pop() <span class="hljs-keyword">if</span> stat.size > maxSize</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-23">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-23">¶</a>
|
||||
</div>
|
||||
<p>Shift off the final blank newline</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.rli.history.shift() <span class="hljs-keyword">if</span> repl.rli.history[<span class="hljs-number">0</span>] <span class="hljs-keyword">is</span> <span class="hljs-string">''</span>
|
||||
repl.rli.historyIndex = <span class="hljs-number">-1</span>
|
||||
lastLine = repl.rli.history[<span class="hljs-number">0</span>]
|
||||
|
||||
fd = fs.openSync filename, <span class="hljs-string">'a'</span>
|
||||
|
||||
repl.rli.addListener <span class="hljs-string">'line'</span>, <span class="hljs-function"><span class="hljs-params">(code)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> code <span class="hljs-keyword">and</span> code.length <span class="hljs-keyword">and</span> code <span class="hljs-keyword">isnt</span> <span class="hljs-string">'.history'</span> <span class="hljs-keyword">and</span> code <span class="hljs-keyword">isnt</span> <span class="hljs-string">'.exit'</span> <span class="hljs-keyword">and</span> lastLine <span class="hljs-keyword">isnt</span> code</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-24">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-24">¶</a>
|
||||
</div>
|
||||
<p>Save the latest command in the file</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> fs.writeSync fd, <span class="hljs-string">"<span class="hljs-subst">#{code}</span>\n"</span>
|
||||
lastLine = code
|
||||
|
||||
repl.<span class="hljs-literal">on</span> <span class="hljs-string">'exit'</span>, <span class="hljs-function">-></span> fs.closeSync fd</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-25">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-25">¶</a>
|
||||
</div>
|
||||
<p>Add a command to show the history stack</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.commands[getCommandId(repl, <span class="hljs-string">'history'</span>)] =
|
||||
help: <span class="hljs-string">'Show command history'</span>
|
||||
action: <span class="hljs-function">-></span>
|
||||
repl.outputStream.write <span class="hljs-string">"<span class="hljs-subst">#{repl.rli.history[..].reverse().join <span class="hljs-string">'\n'</span>}</span>\n"</span>
|
||||
repl.displayPrompt()
|
||||
<span class="hljs-function">
|
||||
<span class="hljs-title">getCommandId</span> = <span class="hljs-params">(repl, commandName)</span> -></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-26">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-26">¶</a>
|
||||
</div>
|
||||
<p>Node 0.11 changed API, a command such as ‘.help’ is now stored as ‘help’</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> commandsHaveLeadingDot = repl.commands[<span class="hljs-string">'.help'</span>]?
|
||||
<span class="hljs-keyword">if</span> commandsHaveLeadingDot <span class="hljs-keyword">then</span> <span class="hljs-string">".<span class="hljs-subst">#{commandName}</span>"</span> <span class="hljs-keyword">else</span> commandName
|
||||
|
||||
<span class="hljs-built_in">module</span>.exports =
|
||||
start: <span class="hljs-function"><span class="hljs-params">(opts = {})</span> -></span>
|
||||
[major, minor, build] = process.versions.node.split(<span class="hljs-string">'.'</span>).map (n) -> parseInt(n)
|
||||
|
||||
<span class="hljs-keyword">if</span> major < <span class="hljs-number">6</span>
|
||||
<span class="hljs-built_in">console</span>.warn <span class="hljs-string">"Node 6+ required for CoffeeScript REPL"</span>
|
||||
process.exit <span class="hljs-number">1</span>
|
||||
|
||||
CoffeeScript.register()
|
||||
process.argv = [<span class="hljs-string">'coffee'</span>].concat process.argv[<span class="hljs-number">2.</span>.]
|
||||
opts = merge replDefaults, opts
|
||||
repl = nodeREPL.start opts
|
||||
runInContext opts.prelude, repl.context, <span class="hljs-string">'prelude'</span> <span class="hljs-keyword">if</span> opts.prelude
|
||||
repl.<span class="hljs-literal">on</span> <span class="hljs-string">'exit'</span>, <span class="hljs-function">-></span> repl.outputStream.write <span class="hljs-string">'\n'</span> <span class="hljs-keyword">if</span> <span class="hljs-keyword">not</span> repl.rli.closed
|
||||
addMultilineHandler repl
|
||||
addHistory repl, opts.historyFile, opts.historyMaxInputSize <span class="hljs-keyword">if</span> opts.historyFile</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-27">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-27">¶</a>
|
||||
</div>
|
||||
<p>Adapt help inherited from the node REPL</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> repl.commands[getCommandId(repl, <span class="hljs-string">'load'</span>)].help = <span class="hljs-string">'Load code from a file into this REPL session'</span>
|
||||
repl</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
1241
docs/v2/annotated-source/rewriter.html
Normal file
398
docs/v2/annotated-source/scope.html
Normal file
@@ -0,0 +1,398 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>scope.litcoffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>scope.litcoffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>The <strong>Scope</strong> class regulates lexical scoping within CoffeeScript. As you
|
||||
generate code, you create a tree of scopes in the same shape as the nested
|
||||
function bodies. Each scope knows about the variables declared within it,
|
||||
and has a reference to its parent enclosing scope. In this way, we know which
|
||||
variables are new and need to be declared with <code>var</code>, and which are shared
|
||||
with external scopes.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre>exports.Scope = <span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Scope</span></span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>Initialize a scope with its parent, for lookups up the chain,
|
||||
as well as a reference to the <strong>Block</strong> node it belongs to, which is
|
||||
where it should declare its variables, a reference to the function that
|
||||
it belongs to, and a list of variables referenced in the source code
|
||||
and therefore should be avoided when generating variables.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> constructor: <span class="hljs-function"><span class="hljs-params">(@parent, @expressions, @method, @referencedVars)</span> -></span>
|
||||
@variables = [{name: <span class="hljs-string">'arguments'</span>, type: <span class="hljs-string">'arguments'</span>}]
|
||||
@positions = {}
|
||||
@utilities = {} <span class="hljs-keyword">unless</span> @parent</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<p>The <code>@root</code> is the top-level <strong>Scope</strong> object for a given file.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> @root = @parent?.root ? <span class="hljs-keyword">this</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Adds a new variable or overrides an existing one.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> add: <span class="hljs-function"><span class="hljs-params">(name, type, immediate)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> @parent.add name, type, immediate <span class="hljs-keyword">if</span> @shared <span class="hljs-keyword">and</span> <span class="hljs-keyword">not</span> immediate
|
||||
<span class="hljs-keyword">if</span> Object::hasOwnProperty.call @positions, name
|
||||
@variables[@positions[name]].type = type
|
||||
<span class="hljs-keyword">else</span>
|
||||
@positions[name] = @variables.push({name, type}) - <span class="hljs-number">1</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>When <code>super</code> is called, we need to find the name of the current method we’re
|
||||
in, so that we know how to invoke the same method of the parent class. This
|
||||
can get complicated if super is being called from an inner function.
|
||||
<code>namedMethod</code> will walk up the scope tree until it either finds the first
|
||||
function object that has a name filled in, or bottoms out.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> namedMethod: <span class="hljs-function">-></span>
|
||||
<span class="hljs-keyword">return</span> @method <span class="hljs-keyword">if</span> @method?.name <span class="hljs-keyword">or</span> !@parent
|
||||
@parent.namedMethod()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Look up a variable name in lexical scope, and declare it if it does not
|
||||
already exist.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> find: <span class="hljs-function"><span class="hljs-params">(name, type = <span class="hljs-string">'var'</span>)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-literal">yes</span> <span class="hljs-keyword">if</span> @check name
|
||||
@add name, type
|
||||
<span class="hljs-literal">no</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<p>Reserve a variable name as originating from a function parameter for this
|
||||
scope. No <code>var</code> required for internal references.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> parameter: <span class="hljs-function"><span class="hljs-params">(name)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> @shared <span class="hljs-keyword">and</span> @parent.check name, <span class="hljs-literal">yes</span>
|
||||
@add name, <span class="hljs-string">'param'</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Just check to see if a variable has already been declared, without reserving,
|
||||
walks up to the root scope.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> check: <span class="hljs-function"><span class="hljs-params">(name)</span> -></span>
|
||||
!!(@type(name) <span class="hljs-keyword">or</span> @parent?.check(name))</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Generate a temporary variable name at the given index.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> temporary: <span class="hljs-function"><span class="hljs-params">(name, index, single=<span class="hljs-literal">false</span>)</span> -></span>
|
||||
<span class="hljs-keyword">if</span> single
|
||||
startCode = name.charCodeAt(<span class="hljs-number">0</span>)
|
||||
endCode = <span class="hljs-string">'z'</span>.charCodeAt(<span class="hljs-number">0</span>)
|
||||
diff = endCode - startCode
|
||||
newCode = startCode + index % (diff + <span class="hljs-number">1</span>)
|
||||
letter = String.fromCharCode(newCode)
|
||||
num = index <span class="hljs-regexp">//</span> (diff + <span class="hljs-number">1</span>)
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{letter}</span><span class="hljs-subst">#{num <span class="hljs-keyword">or</span> <span class="hljs-string">''</span>}</span>"</span>
|
||||
<span class="hljs-keyword">else</span>
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{name}</span><span class="hljs-subst">#{index <span class="hljs-keyword">or</span> <span class="hljs-string">''</span>}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Gets the type of a variable.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> type: <span class="hljs-function"><span class="hljs-params">(name)</span> -></span>
|
||||
<span class="hljs-keyword">return</span> v.type <span class="hljs-keyword">for</span> v <span class="hljs-keyword">in</span> @variables <span class="hljs-keyword">when</span> v.name <span class="hljs-keyword">is</span> name
|
||||
<span class="hljs-literal">null</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>If we need to store an intermediate result, find an available name for a
|
||||
compiler-generated variable. <code>_var</code>, <code>_var2</code>, and so on…</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> freeVariable: <span class="hljs-function"><span class="hljs-params">(name, options={})</span> -></span>
|
||||
index = <span class="hljs-number">0</span>
|
||||
<span class="hljs-keyword">loop</span>
|
||||
temp = @temporary name, index, options.single
|
||||
<span class="hljs-keyword">break</span> <span class="hljs-keyword">unless</span> @check(temp) <span class="hljs-keyword">or</span> temp <span class="hljs-keyword">in</span> @root.referencedVars
|
||||
index++
|
||||
@add temp, <span class="hljs-string">'var'</span>, <span class="hljs-literal">yes</span> <span class="hljs-keyword">if</span> options.reserve ? <span class="hljs-literal">true</span>
|
||||
temp</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>Ensure that an assignment is made at the top of this scope
|
||||
(or at the top-level scope, if requested).</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> assign: <span class="hljs-function"><span class="hljs-params">(name, value)</span> -></span>
|
||||
@add name, {value, assigned: <span class="hljs-literal">yes</span>}, <span class="hljs-literal">yes</span>
|
||||
@hasAssignments = <span class="hljs-literal">yes</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>Does this scope have any declared variables?</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> hasDeclarations: <span class="hljs-function">-></span>
|
||||
!!@declaredVariables().length</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Return the list of variables first declared in this scope.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> declaredVariables: <span class="hljs-function">-></span>
|
||||
(v.name <span class="hljs-keyword">for</span> v <span class="hljs-keyword">in</span> @variables <span class="hljs-keyword">when</span> v.type <span class="hljs-keyword">is</span> <span class="hljs-string">'var'</span>).sort()</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<p>Return the list of assignments that are supposed to be made at the top
|
||||
of this scope.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> assignedVariables: <span class="hljs-function">-></span>
|
||||
<span class="hljs-string">"<span class="hljs-subst">#{v.name}</span> = <span class="hljs-subst">#{v.type.value}</span>"</span> <span class="hljs-keyword">for</span> v <span class="hljs-keyword">in</span> @variables <span class="hljs-keyword">when</span> v.type.assigned</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
523
docs/v2/annotated-source/sourcemap.html
Normal file
@@ -0,0 +1,523 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>sourcemap.litcoffee</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;">
|
||||
<link rel="stylesheet" media="all" href="docco.css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="background"></div>
|
||||
|
||||
<ul id="jump_to">
|
||||
<li>
|
||||
<a class="large" href="javascript:void(0);">Jump To …</a>
|
||||
<a class="small" href="javascript:void(0);">+</a>
|
||||
<div id="jump_wrapper">
|
||||
<div id="jump_page_wrapper">
|
||||
<div id="jump_page">
|
||||
|
||||
|
||||
<a class="source" href="browser.html">
|
||||
browser.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="cake.html">
|
||||
cake.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="coffeescript.html">
|
||||
coffeescript.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="command.html">
|
||||
command.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="grammar.html">
|
||||
grammar.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="helpers.html">
|
||||
helpers.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="index.html">
|
||||
index.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="lexer.html">
|
||||
lexer.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="nodes.html">
|
||||
nodes.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="optparse.html">
|
||||
optparse.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="register.html">
|
||||
register.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="repl.html">
|
||||
repl.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="rewriter.html">
|
||||
rewriter.coffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="scope.html">
|
||||
scope.litcoffee
|
||||
</a>
|
||||
|
||||
|
||||
<a class="source" href="sourcemap.html">
|
||||
sourcemap.litcoffee
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="sections">
|
||||
|
||||
<li id="title">
|
||||
<div class="annotation">
|
||||
<h1>sourcemap.litcoffee</h1>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li id="section-1">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-1">¶</a>
|
||||
</div>
|
||||
<p>Source maps allow JavaScript runtimes to match running JavaScript back to
|
||||
the original source code that corresponds to it. This can be minified
|
||||
JavaScript, but in our case, we’re concerned with mapping pretty-printed
|
||||
JavaScript back to CoffeeScript.</p>
|
||||
<p>In order to produce maps, we must keep track of positions (line number, column number)
|
||||
that originated every node in the syntax tree, and be able to generate a
|
||||
<a href="https://docs.google.com/document/d/1U1RGAehQwRypUTovF1KRlpiOFze0b-_2gc6fAH0KY0k/edit">map file</a>
|
||||
— which is a compact, VLQ-encoded representation of the JSON serialization
|
||||
of this information — to write out alongside the generated JavaScript.</p>
|
||||
<h2 id="linemap">LineMap</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-2">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-2">¶</a>
|
||||
</div>
|
||||
<p>A <strong>LineMap</strong> object keeps track of information about original line and column
|
||||
positions for a single line of output JavaScript code.
|
||||
<strong>SourceMaps</strong> are implemented in terms of <strong>LineMaps</strong>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">LineMap</span></span>
|
||||
constructor: <span class="hljs-function"><span class="hljs-params">(@line)</span> -></span>
|
||||
@columns = []
|
||||
|
||||
add: <span class="hljs-function"><span class="hljs-params">(column, [sourceLine, sourceColumn], options={})</span> -></span>
|
||||
<span class="hljs-keyword">return</span> <span class="hljs-keyword">if</span> @columns[column] <span class="hljs-keyword">and</span> options.noReplace
|
||||
@columns[column] = {line: @line, column, sourceLine, sourceColumn}
|
||||
|
||||
sourceLocation: <span class="hljs-function"><span class="hljs-params">(column)</span> -></span>
|
||||
column-- <span class="hljs-keyword">until</span> (mapping = @columns[column]) <span class="hljs-keyword">or</span> (column <= <span class="hljs-number">0</span>)
|
||||
mapping <span class="hljs-keyword">and</span> [mapping.sourceLine, mapping.sourceColumn]</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-3">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-3">¶</a>
|
||||
</div>
|
||||
<h2 id="sourcemap">SourceMap</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-4">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-4">¶</a>
|
||||
</div>
|
||||
<p>Maps locations in a single generated JavaScript file back to locations in
|
||||
the original CoffeeScript source file.</p>
|
||||
<p>This is intentionally agnostic towards how a source map might be represented on
|
||||
disk. Once the compiler is ready to produce a “v3”-style source map, we can walk
|
||||
through the arrays of line and column buffer to produce it.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">SourceMap</span></span>
|
||||
constructor: <span class="hljs-function">-></span>
|
||||
@lines = []</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-5">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-5">¶</a>
|
||||
</div>
|
||||
<p>Adds a mapping to this SourceMap. <code>sourceLocation</code> and <code>generatedLocation</code>
|
||||
are both <code>[line, column]</code> arrays. If <code>options.noReplace</code> is true, then if there
|
||||
is already a mapping for the specified <code>line</code> and <code>column</code>, this will have no
|
||||
effect.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> add: <span class="hljs-function"><span class="hljs-params">(sourceLocation, generatedLocation, options = {})</span> -></span>
|
||||
[line, column] = generatedLocation
|
||||
lineMap = (@lines[line] <span class="hljs-keyword">or</span>= <span class="hljs-keyword">new</span> LineMap(line))
|
||||
lineMap.add column, sourceLocation, options</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-6">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-6">¶</a>
|
||||
</div>
|
||||
<p>Look up the original position of a given <code>line</code> and <code>column</code> in the generated
|
||||
code.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> sourceLocation: <span class="hljs-function"><span class="hljs-params">([line, column])</span> -></span>
|
||||
line-- <span class="hljs-keyword">until</span> (lineMap = @lines[line]) <span class="hljs-keyword">or</span> (line <= <span class="hljs-number">0</span>)
|
||||
lineMap <span class="hljs-keyword">and</span> lineMap.sourceLocation column</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-7">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-7">¶</a>
|
||||
</div>
|
||||
<h2 id="v3-sourcemap-generation">V3 SourceMap Generation</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-8">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-8">¶</a>
|
||||
</div>
|
||||
<p>Builds up a V3 source map, returning the generated JSON as a string.
|
||||
<code>options.sourceRoot</code> may be used to specify the sourceRoot written to the source
|
||||
map. Also, <code>options.sourceFiles</code> and <code>options.generatedFile</code> may be passed to
|
||||
set “sources” and “file”, respectively.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> generate: <span class="hljs-function"><span class="hljs-params">(options = {}, code = <span class="hljs-literal">null</span>)</span> -></span>
|
||||
writingline = <span class="hljs-number">0</span>
|
||||
lastColumn = <span class="hljs-number">0</span>
|
||||
lastSourceLine = <span class="hljs-number">0</span>
|
||||
lastSourceColumn = <span class="hljs-number">0</span>
|
||||
needComma = <span class="hljs-literal">no</span>
|
||||
buffer = <span class="hljs-string">""</span>
|
||||
|
||||
<span class="hljs-keyword">for</span> lineMap, lineNumber <span class="hljs-keyword">in</span> @lines <span class="hljs-keyword">when</span> lineMap
|
||||
<span class="hljs-keyword">for</span> mapping <span class="hljs-keyword">in</span> lineMap.columns <span class="hljs-keyword">when</span> mapping
|
||||
<span class="hljs-keyword">while</span> writingline < mapping.line
|
||||
lastColumn = <span class="hljs-number">0</span>
|
||||
needComma = <span class="hljs-literal">no</span>
|
||||
buffer += <span class="hljs-string">";"</span>
|
||||
writingline++</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-9">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-9">¶</a>
|
||||
</div>
|
||||
<p>Write a comma if we’ve already written a segment on this line.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> needComma
|
||||
buffer += <span class="hljs-string">","</span>
|
||||
needComma = <span class="hljs-literal">no</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-10">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-10">¶</a>
|
||||
</div>
|
||||
<p>Write the next segment. Segments can be 1, 4, or 5 values. If just one, then it
|
||||
is a generated column which doesn’t match anything in the source code.</p>
|
||||
<p>The starting column in the generated source, relative to any previous recorded
|
||||
column for the current line:</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> buffer += @encodeVlq mapping.column - lastColumn
|
||||
lastColumn = mapping.column</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-11">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-11">¶</a>
|
||||
</div>
|
||||
<p>The index into the list of sources:</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> buffer += @encodeVlq <span class="hljs-number">0</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-12">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-12">¶</a>
|
||||
</div>
|
||||
<p>The starting line in the original source, relative to the previous source line.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> buffer += @encodeVlq mapping.sourceLine - lastSourceLine
|
||||
lastSourceLine = mapping.sourceLine</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-13">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-13">¶</a>
|
||||
</div>
|
||||
<p>The starting column in the original source, relative to the previous column.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> buffer += @encodeVlq mapping.sourceColumn - lastSourceColumn
|
||||
lastSourceColumn = mapping.sourceColumn
|
||||
needComma = <span class="hljs-literal">yes</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-14">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-14">¶</a>
|
||||
</div>
|
||||
<p>Produce the canonical JSON object format for a “v3” source map.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> v3 =
|
||||
version: <span class="hljs-number">3</span>
|
||||
file: options.generatedFile <span class="hljs-keyword">or</span> <span class="hljs-string">''</span>
|
||||
sourceRoot: options.sourceRoot <span class="hljs-keyword">or</span> <span class="hljs-string">''</span>
|
||||
sources: options.sourceFiles <span class="hljs-keyword">or</span> [<span class="hljs-string">''</span>]
|
||||
names: []
|
||||
mappings: buffer
|
||||
|
||||
v3.sourcesContent = [code] <span class="hljs-keyword">if</span> options.inlineMap
|
||||
|
||||
v3</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-15">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-15">¶</a>
|
||||
</div>
|
||||
<h2 id="base64-vlq-encoding">Base64 VLQ Encoding</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-16">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-16">¶</a>
|
||||
</div>
|
||||
<p>Note that SourceMap VLQ encoding is “backwards”. MIDI-style VLQ encoding puts
|
||||
the most-significant-bit (MSB) from the original value into the MSB of the VLQ
|
||||
encoded value (see <a href="http://en.wikipedia.org/wiki/File:Uintvar_coding.svg">Wikipedia</a>).
|
||||
SourceMap VLQ does things the other way around, with the least significat four
|
||||
bits of the original value encoded into the first byte of the VLQ encoded value.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> VLQ_SHIFT = <span class="hljs-number">5</span>
|
||||
VLQ_CONTINUATION_BIT = <span class="hljs-number">1</span> << VLQ_SHIFT <span class="hljs-comment"># 0010 0000</span>
|
||||
VLQ_VALUE_MASK = VLQ_CONTINUATION_BIT - <span class="hljs-number">1</span> <span class="hljs-comment"># 0001 1111</span>
|
||||
|
||||
encodeVlq: <span class="hljs-function"><span class="hljs-params">(value)</span> -></span>
|
||||
answer = <span class="hljs-string">''</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-17">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-17">¶</a>
|
||||
</div>
|
||||
<p>Least significant bit represents the sign.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> signBit = <span class="hljs-keyword">if</span> value < <span class="hljs-number">0</span> <span class="hljs-keyword">then</span> <span class="hljs-number">1</span> <span class="hljs-keyword">else</span> <span class="hljs-number">0</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-18">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-18">¶</a>
|
||||
</div>
|
||||
<p>The next bits are the actual value.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> valueToEncode = (Math.abs(value) << <span class="hljs-number">1</span>) + signBit</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-19">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-19">¶</a>
|
||||
</div>
|
||||
<p>Make sure we encode at least one character, even if valueToEncode is 0.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">while</span> valueToEncode <span class="hljs-keyword">or</span> <span class="hljs-keyword">not</span> answer
|
||||
nextChunk = valueToEncode & VLQ_VALUE_MASK
|
||||
valueToEncode = valueToEncode >> VLQ_SHIFT
|
||||
nextChunk |= VLQ_CONTINUATION_BIT <span class="hljs-keyword">if</span> valueToEncode
|
||||
answer += @encodeBase64 nextChunk
|
||||
|
||||
answer</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-20">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-20">¶</a>
|
||||
</div>
|
||||
<h2 id="regular-base64-encoding">Regular Base64 Encoding</h2>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-21">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-21">¶</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre> BASE64_CHARS = <span class="hljs-string">'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'</span>
|
||||
|
||||
encodeBase64: <span class="hljs-function"><span class="hljs-params">(value)</span> -></span>
|
||||
BASE64_CHARS[value] <span class="hljs-keyword">or</span> <span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error <span class="hljs-string">"Cannot Base64 encode value: <span class="hljs-subst">#{value}</span>"</span></pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
<li id="section-22">
|
||||
<div class="annotation">
|
||||
|
||||
<div class="pilwrap ">
|
||||
<a class="pilcrow" href="#section-22">¶</a>
|
||||
</div>
|
||||
<p>Our API for source maps is just the <code>SourceMap</code> class.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content"><div class='highlight'><pre><span class="hljs-built_in">module</span>.exports = SourceMap</pre></div></div>
|
||||
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
7986
docs/v2/browser-compiler/coffeescript.js
Normal file
4126
docs/v2/index.html
Normal file
13123
docs/v2/test.html
Normal file
@@ -1,9 +0,0 @@
|
||||
launch() if ignition is on
|
||||
|
||||
volume: 10 if band isnt spinal_tap
|
||||
|
||||
let_the_wild_rumpus_begin() unless answer is no
|
||||
|
||||
if car.speed < speed_limit then accelerate()
|
||||
|
||||
print "My name is " + @name
|
||||
@@ -1,4 +0,0 @@
|
||||
backwards: ->
|
||||
alert arguments.reverse()
|
||||
|
||||
backwards "stairway", "to", "heaven"
|
||||
@@ -1,7 +0,0 @@
|
||||
# Eat lunch.
|
||||
lunch: eat(food) for food in ['toast', 'cheese', 'wine']
|
||||
|
||||
# Naive collision detection.
|
||||
for roid in asteroids
|
||||
for roid2 in asteroids when roid isnt roid2
|
||||
roid.explode() if roid.overlaps roid2
|
||||
@@ -1,2 +0,0 @@
|
||||
greeting: "Hello CoffeeScript"
|
||||
difficulty: 0.5
|
||||
@@ -1,5 +0,0 @@
|
||||
cholesterol: 127
|
||||
|
||||
healthy: 200 > cholesterol > 60
|
||||
|
||||
|
||||
@@ -1,9 +0,0 @@
|
||||
mood: greatly_improved if singing
|
||||
|
||||
if happy and knows_it
|
||||
claps_hands()
|
||||
cha_cha_cha()
|
||||
|
||||
date: if friday then sue else jill
|
||||
|
||||
expensive ||= do_the_math()
|
||||
@@ -1,8 +0,0 @@
|
||||
solipsism: true if mind? and not world?
|
||||
|
||||
speed ?= 140
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,9 +0,0 @@
|
||||
grade: (student) ->
|
||||
if student.excellent_work
|
||||
"A+"
|
||||
else if student.okay_stuff
|
||||
if student.tried_hard then "B" else "B-"
|
||||
else
|
||||
"C"
|
||||
|
||||
eldest: if 24 > 21 then "Liz" else "Ike"
|
||||
@@ -1 +0,0 @@
|
||||
six: (one: 1) + (two: 2) + (three: 3)
|
||||
@@ -1,3 +0,0 @@
|
||||
# The first ten global properties.
|
||||
|
||||
globals: (name for name of window)[0...10]
|
||||
@@ -1,6 +0,0 @@
|
||||
Account: (customer, cart) ->
|
||||
@customer: customer
|
||||
@cart: cart
|
||||
|
||||
$('.shopping_cart').bind 'click', (event) =>
|
||||
@customer.purchase @cart
|
||||
@@ -1,2 +0,0 @@
|
||||
square: (x) -> x * x
|
||||
cube: (x) -> square(x) * x
|
||||
@@ -1,5 +0,0 @@
|
||||
html: '''
|
||||
<strong>
|
||||
cup of coffeescript
|
||||
</strong>
|
||||
'''
|
||||
@@ -1,5 +0,0 @@
|
||||
weather_report: (location) ->
|
||||
# Make an Ajax request to fetch the weather...
|
||||
[location, 72, "Mostly Sunny"]
|
||||
|
||||
[city, temp, forecast]: weather_report "Berkeley, CA"
|
||||
@@ -1,4 +0,0 @@
|
||||
years_old: {max: 10, ida: 9, tim: 11}
|
||||
|
||||
ages: for child, age of years_old
|
||||
child + " is " + age
|
||||
@@ -1,13 +0,0 @@
|
||||
song: ["do", "re", "mi", "fa", "so"]
|
||||
|
||||
ages: {
|
||||
max: 10
|
||||
ida: 9
|
||||
tim: 11
|
||||
}
|
||||
|
||||
matrix: [
|
||||
1, 0, 1
|
||||
0, 0, 1
|
||||
1, 1, 0
|
||||
]
|
||||
@@ -1,4 +0,0 @@
|
||||
bait: 1000
|
||||
and_switch: 0
|
||||
|
||||
[bait, and_switch]: [and_switch, bait]
|
||||
@@ -1,6 +0,0 @@
|
||||
countdown: num for num in [10..1]
|
||||
|
||||
egg_delivery: ->
|
||||
for i in [0...eggs.length] by 12
|
||||
dozen_eggs: eggs[i...i+12]
|
||||
deliver new egg_carton(dozen)
|
||||