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

Side by Side Diff: Source/bindings/v8/WorkerScriptController.cpp

Issue 234403004: Rename V8TRYCATCH_* macros in v8/V8BindingMacros.h (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: BOOL*_BOOL -> BOOL* Created 6 years, 8 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 m_workerGlobalScope.script()->forbidExecution(); 176 m_workerGlobalScope.script()->forbidExecution();
177 return ScriptValue(); 177 return ScriptValue();
178 } 178 }
179 179
180 if (block.HasCaught()) { 180 if (block.HasCaught()) {
181 v8::Local<v8::Message> message = block.Message(); 181 v8::Local<v8::Message> message = block.Message();
182 state->hadException = true; 182 state->hadException = true;
183 state->errorMessage = toCoreString(message->Get()); 183 state->errorMessage = toCoreString(message->Get());
184 state->lineNumber = message->GetLineNumber(); 184 state->lineNumber = message->GetLineNumber();
185 state->columnNumber = message->GetStartColumn() + 1; 185 state->columnNumber = message->GetStartColumn() + 1;
186 V8TRYCATCH_FOR_V8STRINGRESOURCE_RETURN(V8StringResource<>, sourceURL, me ssage->GetScriptResourceName(), ScriptValue()); 186 TOSTRING_BOOL(V8StringResource<>, sourceURL, message->GetScriptResourceN ame(), ScriptValue());
187 state->sourceURL = sourceURL; 187 state->sourceURL = sourceURL;
188 state->exception = ScriptValue(block.Exception(), m_isolate); 188 state->exception = ScriptValue(block.Exception(), m_isolate);
189 block.Reset(); 189 block.Reset();
190 } else 190 } else
191 state->hadException = false; 191 state->hadException = false;
192 192
193 if (result.IsEmpty() || result->IsUndefined()) 193 if (result.IsEmpty() || result->IsUndefined())
194 return ScriptValue(); 194 return ScriptValue();
195 195
196 return ScriptValue(result, m_isolate); 196 return ScriptValue(result, m_isolate);
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 m_disableEvalPending = errorMessage; 257 m_disableEvalPending = errorMessage;
258 } 258 }
259 259
260 void WorkerScriptController::rethrowExceptionFromImportedScript(PassRefPtrWillBe RawPtr<ErrorEvent> errorEvent) 260 void WorkerScriptController::rethrowExceptionFromImportedScript(PassRefPtrWillBe RawPtr<ErrorEvent> errorEvent)
261 { 261 {
262 m_errorEventFromImportedScript = errorEvent; 262 m_errorEventFromImportedScript = errorEvent;
263 throwError(V8ThrowException::createError(v8GeneralError, m_errorEventFromImp ortedScript->message(), m_isolate), m_isolate); 263 throwError(V8ThrowException::createError(v8GeneralError, m_errorEventFromImp ortedScript->message(), m_isolate), m_isolate);
264 } 264 }
265 265
266 } // namespace WebCore 266 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/bindings/v8/V8WorkerGlobalScopeEventListener.cpp ('k') | Source/bindings/v8/custom/V8BlobCustomHelpers.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698