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

Side by Side Diff: test/cctest/asmjs/test-asm-typer.cc

Issue 2552873003: [wasm][asm.js] Pass Script with Handle. (Closed)
Patch Set: re-enable 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 | « src/asmjs/asm-wasm-builder.cc ('k') | test/mjsunit/mjsunit.status » ('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 #include <cstring> 5 #include <cstring>
6 #include <functional> 6 #include <functional>
7 #include <iostream> 7 #include <iostream>
8 #include <memory> 8 #include <memory>
9 9
10 #include "src/asmjs/asm-typer.h" 10 #include "src/asmjs/asm-typer.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 std::cerr << "Failed to parse:\n" << source_ << "\n"; 62 std::cerr << "Failed to parse:\n" << source_ << "\n";
63 CHECK(false); 63 CHECK(false);
64 } 64 }
65 65
66 outer_scope_ = info.script_scope(); 66 outer_scope_ = info.script_scope();
67 module_ = info.scope() 67 module_ = info.scope()
68 ->declarations() 68 ->declarations()
69 ->AtForTest(0) 69 ->AtForTest(0)
70 ->AsFunctionDeclaration() 70 ->AsFunctionDeclaration()
71 ->fun(); 71 ->fun();
72 typer_.reset(new AsmTyper(isolate_, zone_, *script_, module_)); 72 typer_.reset(new AsmTyper(isolate_, zone_, script_, module_));
73 73
74 if (validation_type_ == ValidateStatement || 74 if (validation_type_ == ValidateStatement ||
75 validation_type_ == ValidateExpression) { 75 validation_type_ == ValidateExpression) {
76 fun_scope_.reset(new AsmTyper::FunctionScope(typer_.get())); 76 fun_scope_.reset(new AsmTyper::FunctionScope(typer_.get()));
77 77
78 for (Declaration* decl : *module_->scope()->declarations()) { 78 for (Declaration* decl : *module_->scope()->declarations()) {
79 if (FunctionDeclaration* fun_decl = decl->AsFunctionDeclaration()) { 79 if (FunctionDeclaration* fun_decl = decl->AsFunctionDeclaration()) {
80 fun_decl_ = fun_decl; 80 fun_decl_ = fun_decl;
81 break; 81 break;
82 } 82 }
(...skipping 1966 matching lines...) Expand 10 before | Expand all | Expand 10 after
2049 if (!ValidationOf(Module(kTests[ii])) 2049 if (!ValidationOf(Module(kTests[ii]))
2050 ->FailsWithMessage( 2050 ->FailsWithMessage(
2051 "Constant in return must be signed, float, or double.")) { 2051 "Constant in return must be signed, float, or double.")) {
2052 std::cerr << "Test:\n" << kTests[ii]; 2052 std::cerr << "Test:\n" << kTests[ii];
2053 CHECK(false); 2053 CHECK(false);
2054 } 2054 }
2055 } 2055 }
2056 } 2056 }
2057 2057
2058 } // namespace 2058 } // namespace
OLDNEW
« no previous file with comments | « src/asmjs/asm-wasm-builder.cc ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698