Index: pkg/compiler/lib/src/js_backend/codegen/codegen.dart |
diff --git a/pkg/compiler/lib/src/js_backend/codegen/codegen.dart b/pkg/compiler/lib/src/js_backend/codegen/codegen.dart |
index 92852b7e7c04db1ca1b8857971a57c5320b79d5f..cc9a406f7c9b46e8516c849efd5cbf4a888a27b6 100644 |
--- a/pkg/compiler/lib/src/js_backend/codegen/codegen.dart |
+++ b/pkg/compiler/lib/src/js_backend/codegen/codegen.dart |
@@ -883,6 +883,10 @@ class CodeGenerator extends tree_ir.StatementVisitor |
case BuiltinOperator.NumShr: |
// No normalization required since output is always uint32. |
return js.js('# >>> #', args); |
+ case BuiltinOperator.NumBitNot: |
+ return js.js('(~#) >>> 0', args); |
+ case BuiltinOperator.NumNegate: |
+ return js.js('-#', args); |
case BuiltinOperator.StringConcatenate: |
if (args.isEmpty) return js.string(''); |
return args.reduce((e1,e2) => new js.Binary('+', e1, e2)); |