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

Unified Diff: Source/bindings/v8/ExceptionState.h

Issue 219263002: Improve chances for inlining of ExceptionState::throwIfNeeded() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Drop LIKELY. Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/bindings/v8/ExceptionState.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/v8/ExceptionState.h
diff --git a/Source/bindings/v8/ExceptionState.h b/Source/bindings/v8/ExceptionState.h
index fbe338f09251e4ff18d7327696a07aea27008daa..d9c2b05b8efbf964243352d5fbea2f0cb792aa08 100644
--- a/Source/bindings/v8/ExceptionState.h
+++ b/Source/bindings/v8/ExceptionState.h
@@ -86,13 +86,9 @@ public:
bool throwIfNeeded()
{
- if (m_exception.isEmpty()) {
- if (!m_code)
- return false;
- throwDOMException(m_code, String()); // FIXME: Do we ever hit this? If so, where and why?
- }
-
- V8ThrowException::throwError(m_exception.newLocal(m_isolate), m_isolate);
+ if (!hadException())
+ return false;
+ throwException();
return true;
}
@@ -114,6 +110,7 @@ protected:
private:
void setException(v8::Handle<v8::Value>);
+ void throwException();
String addExceptionContext(const String&) const;
« no previous file with comments | « no previous file | Source/bindings/v8/ExceptionState.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698