Skip to content

Commit

Permalink
throw Error 的message和后面栈内容重复
Browse files Browse the repository at this point in the history
  • Loading branch information
bluedoom committed Mar 3, 2022
1 parent e088634 commit 8030a53
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions unity/native_src/Inc/V8Utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,14 +80,7 @@ class FV8Utils
{
v8::Local<v8::Context> Context(Isolate->GetCurrentContext());

// 输出 (filename):(line number): (message).
std::ostringstream stm;
v8::String::Utf8Value FileName(Isolate, Message->GetScriptResourceName());
int LineNum = Message->GetLineNumber(Context).FromJust();
const char * StrFileName = *FileName;
stm << (StrFileName == nullptr ? "unknow file" : StrFileName) << ":" << LineNum << ": " << ExceptionStr;

stm << std::endl;

// 输出调用栈信息
v8::Local<v8::Value> StackTrace;
Expand Down

0 comments on commit 8030a53

Please sign in to comment.