Skip to content

Commit 29ae709

Browse files
authored
Merge pull request #180 from easycoder/dev
Integrate 'float' plugin
2 parents 9bb468e + ce265aa commit 29ae709

File tree

10 files changed

+446
-381
lines changed

10 files changed

+446
-381
lines changed

dist/easycoder-min.js

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/easycoder.js

Lines changed: 26 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,12 @@ const EasyCoder_Core = {
88
const lino = compiler.getLino();
99
compiler.next();
1010
// Get the (first) value
11-
const value1 = compiler.getValue();
11+
let value1;
12+
try {
13+
value1 = compiler.getValue();
14+
} catch (err) {
15+
return false;
16+
}
1217
if (compiler.tokenIs(`to`)) {
1318
compiler.next();
1419
// Check if a value holder is next
@@ -424,14 +429,19 @@ const EasyCoder_Core = {
424429

425430
compile: compiler => {
426431
const lino = compiler.getLino();
427-
var target;
432+
let target;
428433
if (compiler.nextIsSymbol()) {
429434
// It may be the target
430435
const symbol = compiler.getSymbol();
431436
target = compiler.getCommandAt(symbol.pc).name;
432437
}
433438
// Get the value even if we have a target
434-
const value1 = compiler.getValue();
439+
let value1;
440+
try {
441+
value1 = compiler.getValue();
442+
} catch (err) {
443+
return false;
444+
}
435445
if (compiler.tokenIs(`by`)) {
436446
compiler.next();
437447
}
@@ -887,14 +897,19 @@ const EasyCoder_Core = {
887897
compile: compiler => {
888898
const lino = compiler.getLino();
889899
compiler.next();
890-
var target;
900+
let target;
891901
if (compiler.isSymbol()) {
892902
// It may be the target
893903
const symbol = compiler.getSymbol();
894904
target = compiler.getCommandAt(symbol.pc).name;
895905
}
896906
// Get the value even if we have a target
897-
const value1 = compiler.getValue();
907+
let value1;
908+
try {
909+
value1 = compiler.getValue();
910+
} catch (err) {
911+
return false;
912+
}
898913
if (compiler.tokenIs(`by`)) {
899914
compiler.next();
900915
}
@@ -1866,7 +1881,12 @@ const EasyCoder_Core = {
18661881
const lino = compiler.getLino();
18671882
compiler.next();
18681883
// Get the (first) value
1869-
const value1 = compiler.getValue();
1884+
let value1;
1885+
try {
1886+
value1 = compiler.getValue();
1887+
} catch (err) {
1888+
return false;
1889+
}
18701890
if (compiler.tokenIs(`from`)) {
18711891
compiler.next();
18721892
if (compiler.isSymbol()) {

0 commit comments

Comments
 (0)