diff --git a/src/index.html b/src/index.html
index 5646263..0989be4 100644
--- a/src/index.html
+++ b/src/index.html
@@ -83,13 +83,19 @@
- Supported Bitwise Operations
+ Supported Bitwise Operations
+
+
+ as implemented in JavaScript engine
+
+
& — bitwise AND
| — bitwise inclusive OR
^ — bitwise exclusive XOR
<< — left shift
- >> — right shift
+ >> — sign propagating right shift
+ >>> — zero-fill right shift
diff --git a/src/js/app/bitwise/expression.js b/src/js/app/bitwise/expression.js
index 80028c9..3722092 100644
--- a/src/js/app/bitwise/expression.js
+++ b/src/js/app/bitwise/expression.js
@@ -1,7 +1,7 @@
app.set('expression', function() {
"use strict";
- var exprRegex = /^(-?(?:\d+|0x[\d,a-f]+))\s*(<<|>>|\||\&|\^)\s*(-?(?:\d+|0x[\d,a-f]+))$/;
+ var exprRegex = /^(-?(?:\d+|0x[\d,a-f]+))\s*(<<|>>|>>>|\||\&|\^)\s*(-?(?:\d+|0x[\d,a-f]+))$/;
var listRegex = /^(-?(?:\d+|0x[\d,a-f]+)\s?)+$/;
return {
diff --git a/tests/domain/expressionSpec.js b/tests/domain/expressionSpec.js
index f947c52..fb28034 100644
--- a/tests/domain/expressionSpec.js
+++ b/tests/domain/expressionSpec.js
@@ -18,7 +18,8 @@ describe("expression parse", function() {
"23^0x1": { operand1: 23, operand2:1, "sign":"^", string: "23^0x1" },
"0xf>>0xa": { operand1: 15, operand2:10, "sign":">>", string:"0xf>>0xa" },
"0x10&0x11": { operand1: 0x10, operand2:0x11, "sign":"&", string:"0x10&0x11" },
- "0x1a^11": { operand1: 0x1a, operand2:11, "sign":"^", string:"0x1a^11" }
+ "0x1a^11": { operand1: 0x1a, operand2:11, "sign":"^", string:"0x1a^11" },
+ "0x1a>>>11": { operand1: 0x1a, operand2:11, "sign":">>>", string:"0x1a>>>11" }
};
it("should parse expressions", function() {