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

Issue 995203002: bindings: Add a macro for V8 Maybe<T> APIs. (Closed)

Created:
5 years, 9 months ago by bashi
Modified:
5 years, 9 months ago
Reviewers:
haraken, Jens Widell, Yuki
CC:
blink-reviews, blink-reviews-bindings_chromium.org, vivekg_samsung, arv+blink, vivekg
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

bindings: Add a macro for V8 Maybe<T> APIs. These APIs require !IsNothing() check before getting values. It's worth adding a macro which does the check. BUG=462402 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=191704

Patch Set 1 #

Total comments: 6

Patch Set 2 : #

Total comments: 2

Patch Set 3 : #

Total comments: 6

Patch Set 4 : #

Patch Set 5 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+43 lines, -11 lines) Patch
M Source/bindings/core/v8/V8BindingMacros.h View 1 2 3 4 1 chunk +15 lines, -0 lines 0 comments Download
M Source/bindings/modules/v8/custom/V8CustomSQLStatementErrorCallback.cpp View 1 2 chunks +6 lines, -1 line 0 comments Download
M Source/bindings/modules/v8/custom/V8DeviceMotionEventCustom.cpp View 1 3 chunks +17 lines, -8 lines 0 comments Download
M Source/bindings/modules/v8/custom/V8DeviceOrientationEventCustom.cpp View 1 1 chunk +5 lines, -2 lines 0 comments Download

Messages

Total messages: 21 (6 generated)
bashi
I think it's worth adding a macro for v8::Maybe<T>. WDYT?
5 years, 9 months ago (2015-03-11 02:16:37 UTC) #2
bashi
Forgot to put a link to Maybe<T>. https://code.google.com/p/chromium/codesearch#chromium/src/v8/include/v8.h&q=Maybe&sq=package:chromium&l=5867
5 years, 9 months ago (2015-03-11 02:17:49 UTC) #3
haraken
https://codereview.chromium.org/995203002/diff/1/Source/bindings/core/v8/V8BindingMacros.h File Source/bindings/core/v8/V8BindingMacros.h (right): https://codereview.chromium.org/995203002/diff/1/Source/bindings/core/v8/V8BindingMacros.h#newcode90 Source/bindings/core/v8/V8BindingMacros.h:90: if (handle.IsEmpty() || !v8Maybe(handle->methodCall, outVariable)) { \ Do we ...
5 years, 9 months ago (2015-03-11 02:43:21 UTC) #4
bashi
Thank you for review! https://codereview.chromium.org/995203002/diff/1/Source/bindings/core/v8/V8BindingMacros.h File Source/bindings/core/v8/V8BindingMacros.h (right): https://codereview.chromium.org/995203002/diff/1/Source/bindings/core/v8/V8BindingMacros.h#newcode90 Source/bindings/core/v8/V8BindingMacros.h:90: if (handle.IsEmpty() || !v8Maybe(handle->methodCall, outVariable)) ...
5 years, 9 months ago (2015-03-11 03:46:27 UTC) #5
haraken
LGTM on my side. Jens?
5 years, 9 months ago (2015-03-11 03:54:13 UTC) #6
Jens Widell
LGTM https://codereview.chromium.org/995203002/diff/20001/Source/bindings/core/v8/V8BindingMacros.h File Source/bindings/core/v8/V8BindingMacros.h (right): https://codereview.chromium.org/995203002/diff/20001/Source/bindings/core/v8/V8BindingMacros.h#newcode90 Source/bindings/core/v8/V8BindingMacros.h:90: if (handle.IsEmpty() || !getValueFromMaybe(handle->methodCall, outVariable)) { \ Wrap ...
5 years, 9 months ago (2015-03-11 07:18:22 UTC) #7
bashi
Thanks! https://codereview.chromium.org/995203002/diff/20001/Source/bindings/core/v8/V8BindingMacros.h File Source/bindings/core/v8/V8BindingMacros.h (right): https://codereview.chromium.org/995203002/diff/20001/Source/bindings/core/v8/V8BindingMacros.h#newcode90 Source/bindings/core/v8/V8BindingMacros.h:90: if (handle.IsEmpty() || !getValueFromMaybe(handle->methodCall, outVariable)) { \ On ...
5 years, 9 months ago (2015-03-11 07:33:43 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/995203002/40001
5 years, 9 months ago (2015-03-11 07:36:19 UTC) #11
Jens Widell
https://codereview.chromium.org/995203002/diff/40001/Source/bindings/core/v8/V8BindingMacros.h File Source/bindings/core/v8/V8BindingMacros.h (right): https://codereview.chromium.org/995203002/diff/40001/Source/bindings/core/v8/V8BindingMacros.h#newcode92 Source/bindings/core/v8/V8BindingMacros.h:92: do { \ This inner do{}while() is OTOH strictly ...
5 years, 9 months ago (2015-03-11 07:39:34 UTC) #12
bashi
https://codereview.chromium.org/995203002/diff/40001/Source/bindings/core/v8/V8BindingMacros.h File Source/bindings/core/v8/V8BindingMacros.h (right): https://codereview.chromium.org/995203002/diff/40001/Source/bindings/core/v8/V8BindingMacros.h#newcode92 Source/bindings/core/v8/V8BindingMacros.h:92: do { \ On 2015/03/11 07:39:34, Jens Widell wrote: ...
5 years, 9 months ago (2015-03-11 07:51:18 UTC) #14
Yuki
https://codereview.chromium.org/995203002/diff/40001/Source/bindings/core/v8/V8BindingMacros.h File Source/bindings/core/v8/V8BindingMacros.h (right): https://codereview.chromium.org/995203002/diff/40001/Source/bindings/core/v8/V8BindingMacros.h#newcode81 Source/bindings/core/v8/V8BindingMacros.h:81: bool inline getValueFromMaybe(v8::Maybe<T> maybe, T& outVariable) nit: s/bool inline/inline ...
5 years, 9 months ago (2015-03-11 07:55:22 UTC) #15
Yuki
lgtm
5 years, 9 months ago (2015-03-11 07:56:36 UTC) #16
bashi
https://codereview.chromium.org/995203002/diff/40001/Source/bindings/core/v8/V8BindingMacros.h File Source/bindings/core/v8/V8BindingMacros.h (right): https://codereview.chromium.org/995203002/diff/40001/Source/bindings/core/v8/V8BindingMacros.h#newcode81 Source/bindings/core/v8/V8BindingMacros.h:81: bool inline getValueFromMaybe(v8::Maybe<T> maybe, T& outVariable) On 2015/03/11 07:55:22, ...
5 years, 9 months ago (2015-03-11 10:22:35 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/995203002/80001
5 years, 9 months ago (2015-03-11 10:22:57 UTC) #20
commit-bot: I haz the power
5 years, 9 months ago (2015-03-11 13:25:22 UTC) #21
Message was sent while issue was closed.
Committed patchset #5 (id:80001) as
https://src.chromium.org/viewvc/blink?view=rev&revision=191704

Powered by Google App Engine
This is Rietveld 408576698