mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-23 13:15:46 +01:00
Fix io.source heredoc parsing in FF36. Closes issue #32.
This commit is contained in:
@@ -362,11 +362,15 @@ lookup:
|
|||||||
|
|
||||||
this.readHeredoc = function (end) {
|
this.readHeredoc = function (end) {
|
||||||
let res = [];
|
let res = [];
|
||||||
for (let [i, line] in iter)
|
try {
|
||||||
if (line === end)
|
while (true)
|
||||||
return res.join("\n");
|
let ([i, line] = iter.next()) {
|
||||||
else
|
if (line === end)
|
||||||
res.push(line);
|
return res.join("\n");
|
||||||
|
res.push(line);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (e if e instanceof StopIteration) {}
|
||||||
dactyl.assert(false, "Unexpected end of file waiting for " + end);
|
dactyl.assert(false, "Unexpected end of file waiting for " + end);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user