blob: f3cd2dd94ee0a466f9b1ee00fce9172588e1af88 [file] [log] [blame]
Emily Bernierd0a1eb72015-03-24 16:35:39 -04001// Copyright 2015 the V8 project authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5(function Module(stdlib, foreign, heap) {
6 "use asm";
7 // This is not valid asm.js, but should nevertheless work.
8 var MEM = new Uint8ClampedArray(heap);
9 function foo( ) { MEM[0] ^= 1; }
10 return {foo: foo};
11})(this, {}, new ArrayBuffer( ) ).foo();