| Index: include/v8.h
|
| diff --git a/include/v8.h b/include/v8.h
|
| index 51fb1330614237fe6a1e735d9ff5d44798fd552e..25bfbf38064d12ce9646a11b5fc4d211ebac2838 100644
|
| --- a/include/v8.h
|
| +++ b/include/v8.h
|
| @@ -1528,6 +1528,7 @@ class V8_EXPORT Message {
|
| static const int kNoLineNumberInfo = 0;
|
| static const int kNoColumnInfo = 0;
|
| static const int kNoScriptIdInfo = 0;
|
| + static const uint32_t kNoWasmByteOffsetInfo = static_cast<uint32_t>(-1);
|
| };
|
|
|
|
|
| @@ -1552,7 +1553,11 @@ class V8_EXPORT StackTrace {
|
| kScriptNameOrSourceURL = 1 << 6,
|
| kScriptId = 1 << 7,
|
| kExposeFramesAcrossSecurityOrigins = 1 << 8,
|
| - kOverview = kLineNumber | kColumnOffset | kScriptName | kFunctionName,
|
| + kIsWasm = 1 << 9,
|
| + kWasmByteOffset = 1 << 10,
|
| + kWasmObject = 1 << 11,
|
| + kOverview = kLineNumber | kColumnOffset | kScriptName | kFunctionName |
|
| + kIsWasm | kWasmByteOffset | kWasmObject,
|
| kDetailed = kOverview | kIsEval | kIsConstructor | kScriptNameOrSourceURL
|
| };
|
|
|
| @@ -1645,6 +1650,27 @@ class V8_EXPORT StackFrame {
|
| * constructor via "new".
|
| */
|
| bool IsConstructor() const;
|
| +
|
| + /**
|
| + * Returns whether or not the associated function is a wasm function.
|
| + * Always returns false if kIsWasm was not passed as an option when capturing
|
| + * the StackTrace.
|
| + */
|
| + bool IsWasm() const;
|
| +
|
| + /**
|
| + * Returns the wasm object, or undefined if the associated function of the
|
| + * frame is no wasm function or if kWasmObject was not passed as an option
|
| + * when capturing the StackTrace.
|
| + */
|
| + Local<Object> GetWasmObject() const;
|
| +
|
| + /**
|
| + * Returns the byte offset in the associated wasm function, or
|
| + * Message::kNoWasmByteOffsetInfo if the associated function of the frame is
|
| + * no wasm function.
|
| + */
|
| + uint32_t GetWasmByteOffset() const;
|
| };
|
|
|
|
|
|
|