1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-28 14:15:07 +00:00

LibJS: Add basic support for modulo (%) in binary expressions

This commit is contained in:
Andreas Kling 2020-04-04 21:17:34 +02:00
parent 9c8363bb5f
commit 644ff1bbfd
6 changed files with 25 additions and 0 deletions

View file

@ -0,0 +1,8 @@
function assert(x) { if (!x) throw 1; }
try {
assert(10 % 3 === 1);
console.log("PASS");
} catch (e) {
console.log("FAIL: " + e);
}