Lines Matching defs:const
41 WasmError(uint32_t offset, const char* format, ...) : offset_(offset) {
50 bool empty() const { return message_.empty(); }
51 bool has_error() const { return !message_.empty(); }
53 uint32_t offset() const { return offset_; }
54 const std::string& message() const& { return message_; }
58 static std::string FormatError(const char* format, va_list args);
70 Result(const Result&) = delete;
71 Result& operator=(const Result&) = delete;
89 bool ok() const { return error_.empty(); }
90 bool failed() const { return error_.has_error(); }
91 const WasmError& error() const& { return error_; }
94 // Accessor for the value. Returns const reference if {this} is l-value or
95 // const, and returns r-value reference if {this} is r-value. This allows to
98 const T& value() const & {
118 ErrorThrower(Isolate* isolate, const char* context)
122 ErrorThrower(const ErrorThrower&) = delete;
123 ErrorThrower& operator=(const ErrorThrower&) = delete;
126 PRINTF_FORMAT(2, 3) void TypeError(const char* fmt, ...);
127 PRINTF_FORMAT(2, 3) void RangeError(const char* fmt, ...);
128 PRINTF_FORMAT(2, 3) void CompileError(const char* fmt, ...);
129 PRINTF_FORMAT(2, 3) void LinkError(const char* fmt, ...);
130 PRINTF_FORMAT(2, 3) void RuntimeError(const char* fmt, ...);
132 void CompileFailed(const WasmError& error) {
143 bool error() const { return error_type_ != kNone; }
145 const char* error_msg() { return error_msg_.c_str(); }
147 Isolate* isolate() const { return isolate_; }
164 void Format(ErrorType error_type_, const char* fmt, va_list);
167 const char* context_;
184 ScheduledErrorThrower(i::Isolate* isolate, const char* context)