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

Side by Side Diff: src/asmjs/asm-typer.h

Issue 2614563002: [wasm][asm.js] Cancel exception and rethrow on parse failure. (Closed)
Patch Set: fix Created 3 years, 11 months 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 | « no previous file | src/asmjs/asm-typer.cc » ('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 #ifndef SRC_ASMJS_ASM_TYPER_H_ 5 #ifndef SRC_ASMJS_ASM_TYPER_H_
6 #define SRC_ASMJS_ASM_TYPER_H_ 6 #define SRC_ASMJS_ASM_TYPER_H_
7 7
8 #include <cstdint> 8 #include <cstdint>
9 #include <string> 9 #include <string>
10 #include <unordered_map> 10 #include <unordered_map>
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 bool Validate(); 75 bool Validate();
76 // Do asm.js validation in phases (to interleave with conversion to wasm). 76 // Do asm.js validation in phases (to interleave with conversion to wasm).
77 bool ValidateBeforeFunctionsPhase(); 77 bool ValidateBeforeFunctionsPhase();
78 bool ValidateInnerFunction(FunctionDeclaration* decl); 78 bool ValidateInnerFunction(FunctionDeclaration* decl);
79 bool ValidateAfterFunctionsPhase(); 79 bool ValidateAfterFunctionsPhase();
80 void ClearFunctionNodeTypes(); 80 void ClearFunctionNodeTypes();
81 81
82 Handle<JSMessageObject> error_message() const { return error_message_; } 82 Handle<JSMessageObject> error_message() const { return error_message_; }
83 const MessageLocation* message_location() const { return &message_location_; } 83 const MessageLocation* message_location() const { return &message_location_; }
84 84
85 AsmType* TriggerParsingError();
86
85 AsmType* TypeOf(AstNode* node) const; 87 AsmType* TypeOf(AstNode* node) const;
86 AsmType* TypeOf(Variable* v) const; 88 AsmType* TypeOf(Variable* v) const;
87 StandardMember VariableAsStandardMember(Variable* var); 89 StandardMember VariableAsStandardMember(Variable* var);
88 90
89 // Allow the asm-wasm-builder to trigger failures (for interleaved 91 // Allow the asm-wasm-builder to trigger failures (for interleaved
90 // validating). 92 // validating).
91 AsmType* FailWithMessage(const char* text); 93 AsmType* FailWithMessage(const char* text);
92 94
93 typedef std::unordered_set<StandardMember, std::hash<int> > StdlibSet; 95 typedef std::unordered_set<StandardMember, std::hash<int> > StdlibSet;
94 96
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after
409 ZoneVector<Assignment*> function_pointer_tables_; 411 ZoneVector<Assignment*> function_pointer_tables_;
410 412
411 DISALLOW_IMPLICIT_CONSTRUCTORS(AsmTyper); 413 DISALLOW_IMPLICIT_CONSTRUCTORS(AsmTyper);
412 }; 414 };
413 415
414 } // namespace wasm 416 } // namespace wasm
415 } // namespace internal 417 } // namespace internal
416 } // namespace v8 418 } // namespace v8
417 419
418 #endif // SRC_ASMJS_ASM_TYPER_H_ 420 #endif // SRC_ASMJS_ASM_TYPER_H_
OLDNEW
« no previous file with comments | « no previous file | src/asmjs/asm-typer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698