Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(547)

Side by Side Diff: test/inspector/debugger/wasm-source.js

Issue 2594993002: [wasm] Rename wasm::LocalType to wasm::ValueType and kAst* to kWasm* (Closed)
Patch Set: Fix inspector tests Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « test/inspector/debugger/wasm-scripts.js ('k') | test/inspector/debugger/wasm-stack.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Flags: --expose-wasm 5 // Flags: --expose-wasm
6 6
7 load('test/mjsunit/wasm/wasm-constants.js'); 7 load('test/mjsunit/wasm/wasm-constants.js');
8 load('test/mjsunit/wasm/wasm-module-builder.js'); 8 load('test/mjsunit/wasm/wasm-module-builder.js');
9 9
10 var builder = new WasmModuleBuilder(); 10 var builder = new WasmModuleBuilder();
11 11
12 var imported_idx = builder.addImport("xxx", "func", kSig_v_v); 12 var imported_idx = builder.addImport("xxx", "func", kSig_v_v);
13 13
14 var call_imported_idx = builder.addFunction("call_func", kSig_v_v) 14 var call_imported_idx = builder.addFunction("call_func", kSig_v_v)
15 .addBody([kExprCallFunction, imported_idx]) 15 .addBody([kExprCallFunction, imported_idx])
16 .index; 16 .index;
17 17
18 var sig_index = builder.addType(kSig_v_v); 18 var sig_index = builder.addType(kSig_v_v);
19 19
20 builder.addFunction('main', kSig_v_v) 20 builder.addFunction('main', kSig_v_v)
21 .addBody([ 21 .addBody([
22 kExprBlock, kAstStmt, kExprI32Const, 0, kExprCallIndirect, sig_index, 22 kExprBlock, kWasmStmt, kExprI32Const, 0, kExprCallIndirect, sig_index,
23 kTableZero, kExprEnd 23 kTableZero, kExprEnd
24 ]) 24 ])
25 .exportAs('main'); 25 .exportAs('main');
26 26
27 builder.appendToTable([call_imported_idx]); 27 builder.appendToTable([call_imported_idx]);
28 28
29 var module_bytes = builder.toArray(); 29 var module_bytes = builder.toArray();
30 30
31 function testFunction(bytes) { 31 function testFunction(bytes) {
32 function call_debugger() { 32 function call_debugger() {
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 .getScriptSource({scriptId: frames[frameId].location.scriptId}) 70 .getScriptSource({scriptId: frames[frameId].location.scriptId})
71 .then(dumpSourceLine.bind(null, frameId)) 71 .then(dumpSourceLine.bind(null, frameId))
72 .then(() => next(frameId + 1)); 72 .then(() => next(frameId + 1));
73 } 73 }
74 function finished() { 74 function finished() {
75 InspectorTest.log('Finished.'); 75 InspectorTest.log('Finished.');
76 InspectorTest.completeTest(); 76 InspectorTest.completeTest();
77 } 77 }
78 next(0).then(finished); 78 next(0).then(finished);
79 } 79 }
OLDNEW
« no previous file with comments | « test/inspector/debugger/wasm-scripts.js ('k') | test/inspector/debugger/wasm-stack.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698