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

Issue 808373002: IDL: Simplify [TypeChecking=Interface] code generation (Closed)

Created:
6 years ago by Jens Widell
Modified:
6 years ago
Reviewers:
haraken
CC:
blink-reviews, blink-reviews-bindings_chromium.org, arv+blink
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

IDL: Simplify [TypeChecking=Interface] code generation Instead of doing a separate hasInstance() check before converting, simply use toImplWithTypeCheck() to convert and check after if the result was null, as it is if not hasInstance(). The primary benefit of this is that we no longer need to optimize away the extra hasInstance() check in toImplWithTypeCheck() by using an "unsafe" conversion in the [TypeChecking=Interface] case. This simplifies the code generator without losing the optimization. Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=187476

Patch Set 1 #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+76 lines, -92 lines) Patch
M Source/bindings/scripts/v8_attributes.py View 2 chunks +1 line, -6 lines 0 comments Download
M Source/bindings/scripts/v8_methods.py View 3 chunks +4 lines, -9 lines 0 comments Download
M Source/bindings/scripts/v8_types.py View 4 chunks +4 lines, -7 lines 0 comments Download
M Source/bindings/templates/attributes.cpp View 2 chunks +8 lines, -10 lines 0 comments Download
M Source/bindings/templates/methods.cpp View 2 chunks +10 lines, -11 lines 0 comments Download
M Source/bindings/tests/results/core/V8TestInterface.cpp View 8 chunks +20 lines, -20 lines 2 comments Download
M Source/bindings/tests/results/core/V8TestObject.cpp View 6 chunks +20 lines, -20 lines 2 comments Download
M Source/bindings/tests/results/modules/V8TestInterface5.cpp View 2 chunks +5 lines, -5 lines 0 comments Download
M Source/bindings/tests/results/modules/V8TestInterfacePartial.cpp View 2 chunks +4 lines, -4 lines 0 comments Download

Messages

Total messages: 6 (2 generated)
Jens Widell
PTAL https://codereview.chromium.org/808373002/diff/1/Source/bindings/tests/results/core/V8TestInterface.cpp File Source/bindings/tests/results/core/V8TestInterface.cpp (right): https://codereview.chromium.org/808373002/diff/1/Source/bindings/tests/results/core/V8TestInterface.cpp#newcode1154 Source/bindings/tests/results/core/V8TestInterface.cpp:1154: window = toDOMWindow(info.GetIsolate(), info[0]); This is a real ...
6 years ago (2014-12-18 13:47:05 UTC) #2
haraken
LGTM, nice change. https://codereview.chromium.org/808373002/diff/1/Source/bindings/tests/results/core/V8TestInterface.cpp File Source/bindings/tests/results/core/V8TestInterface.cpp (right): https://codereview.chromium.org/808373002/diff/1/Source/bindings/tests/results/core/V8TestInterface.cpp#newcode1154 Source/bindings/tests/results/core/V8TestInterface.cpp:1154: window = toDOMWindow(info.GetIsolate(), info[0]); On 2014/12/18 ...
6 years ago (2014-12-18 14:50:27 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/808373002/1
6 years ago (2014-12-18 15:38:32 UTC) #5
commit-bot: I haz the power
6 years ago (2014-12-18 17:03:19 UTC) #6
Message was sent while issue was closed.
Committed patchset #1 (id:1) as
https://src.chromium.org/viewvc/blink?view=rev&revision=187476

Powered by Google App Engine
This is Rietveld 408576698