[webkit-reviews] review granted: [Bug 190163] Create a RELEASE_AND_RETURN macro for ExceptionScopes : [Attachment 351300] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Oct 1 14:44:19 PDT 2018
Mark Lam <mark.lam at apple.com> has granted Keith Miller
<keith_miller at apple.com>'s request for review:
Bug 190163: Create a RELEASE_AND_RETURN macro for ExceptionScopes
https://bugs.webkit.org/show_bug.cgi?id=190163
Attachment 351300: Patch
https://bugs.webkit.org/attachment.cgi?id=351300&action=review
--- Comment #2 from Mark Lam <mark.lam at apple.com> ---
Comment on attachment 351300
--> https://bugs.webkit.org/attachment.cgi?id=351300
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=351300&action=review
r=me with unnecessary braces removed.
> Source/JavaScriptCore/dfg/DFGOperations.cpp:266
> if (prototype.isObject()) {
> - scope.release();
> - return constructEmptyObject(exec, asObject(prototype));
> + RELEASE_AND_RETURN(scope, constructEmptyObject(exec,
asObject(prototype)));
> }
Don't need braces anymore. Ditto many places below.
> Source/JavaScriptCore/runtime/ExceptionScope.h:96
> +#define RELEASE_AND_RETURN(scope__, expression__) do { \
Pity that this name is so much more generic that RETURN_IF_EXCEPTION, but no
one else has this idiom yet. So, I'm ok going with this until there's a need
to rename it.
More information about the webkit-reviews
mailing list