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

Issue 2513893002: Make ifdefs consistent in WebKit/Source/core/ (Closed)

Created:
4 years, 1 month ago by Alexander Alekseev
Modified:
4 years ago
CC:
chromium-reviews, tzik, blink-reviews-platform-graphics_chromium.org, dshwang, eae+blinkwatch, fs, kouhei+svg_chromium.org, rwlbuis, krit, drott+blinkwatch_chromium.org, szager+layoutwatch_chromium.org, Justin Novosad, Rik, jchaffraix+rendering, blink-reviews, gyuyoung2, pdr+svgwatchlist_chromium.org, ajuma+watch_chromium.org, Mads Ager (chromium), zoltan1, blink-reviews-layout_chromium.org, jbroman, pdr+graphicswatchlist_chromium.org, haraken, danakj+watch_chromium.org, pdr+renderingwatchlist_chromium.org, leviw+renderwatch, f(malita), oilpan-reviews, kouhei+heap_chromium.org, kinuko+fileapi, nhiroki
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Make ifdefs consistent in WebKit/Source/core/ . This CL addresses a few problems with #ifdefs: 1) DCHECK requires the presence of variables used in it even if DCHECK_IS_ON() evaluates to 0. Therefore, if debug variable is defined only when DCHECK_IS_ON() is true, its usage must be guarded the same way. 2) If debug method in base class is defined only when DCHECK_IS_ON() is true, its descendants must be guarded with the same check. BUG=666660 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Committed: https://crrev.com/5dd87e237131833c489f0b3ce5b231526318b37c Cr-Commit-Position: refs/heads/master@{#435865}

Patch Set 1 #

Total comments: 4

Patch Set 2 : Update after review. #

Patch Set 3 : Fix build #

Patch Set 4 : Fix build. Update after review. #

Total comments: 9

Patch Set 5 : Fix build. #

Patch Set 6 : Added #if DCHECK_IS_ON where needed. #

Total comments: 25

Patch Set 7 : Rebased. #

Patch Set 8 : Limited fix to /core/ only. #

Total comments: 1

Patch Set 9 : Allow show* functions in debug build. #

Total comments: 2

Patch Set 10 : Remove extra #include #

Total comments: 8

Patch Set 11 : Revert small part #

Unified diffs Side-by-side diffs Delta from patch set Stats (+20 lines, -14 lines) Patch
M third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp View 1 2 3 4 5 2 chunks +6 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutObject.h View 1 2 3 4 5 6 7 8 9 10 5 chunks +5 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutObject.cpp View 1 2 3 4 5 6 7 8 9 5 chunks +7 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/svg/SVGScriptElement.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/svg/SVGScriptElement.cpp View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 76 (45 generated)
Alexander Alekseev
Please review: nhiroki@ : modules/filesystem/FileWriterSync.cpp pdr@ : All the other files.
4 years, 1 month ago (2016-11-18 08:38:12 UTC) #5
mstensho (USE GERRIT)
I didn't go through everything, but it seems to me that you could just switch ...
4 years, 1 month ago (2016-11-18 08:45:54 UTC) #7
Yuta Kitamura
Generally speaking, you should NOT guard ASSERT with DCHECK_IS_ON. ASSERT should automatically do that for ...
4 years, 1 month ago (2016-11-18 09:29:51 UTC) #11
Alexander Alekseev
On 2016/11/18 09:29:51, Yuta Kitamura wrote: > Generally speaking, you should NOT guard ASSERT with ...
4 years, 1 month ago (2016-11-18 22:32:15 UTC) #14
Alexander Alekseev
I put back some of "#if IS_DCHECK_ON()" because DCHECK actually requires its arguments to build ...
4 years, 1 month ago (2016-11-19 05:07:52 UTC) #27
nhiroki
I'm a bit confused about these changes. You mean DCHECK() can be tested even if ...
4 years, 1 month ago (2016-11-21 03:24:27 UTC) #28
nhiroki
https://codereview.chromium.org/2513893002/diff/100001/third_party/WebKit/Source/modules/filesystem/FileWriterSync.cpp File third_party/WebKit/Source/modules/filesystem/FileWriterSync.cpp (right): https://codereview.chromium.org/2513893002/diff/100001/third_party/WebKit/Source/modules/filesystem/FileWriterSync.cpp#newcode44 third_party/WebKit/Source/modules/filesystem/FileWriterSync.cpp:44: #if DCHECK_IS_ON() Instead of adding DCHECK_IS_ON(), can you completely ...
4 years, 1 month ago (2016-11-21 03:24:57 UTC) #29
Yuta Kitamura
Almost all of the changes are incorrect, hence NOT LGTM. To disable DCHECK/ASSERT, you should ...
4 years, 1 month ago (2016-11-21 05:32:06 UTC) #30
nhiroki
On 2016/11/21 05:32:06, Yuta Kitamura wrote: > Almost all of the changes are incorrect, hence ...
4 years, 1 month ago (2016-11-21 06:23:15 UTC) #31
Yuta Kitamura
On 2016/11/21 06:23:15, nhiroki wrote: > On 2016/11/21 05:32:06, Yuta Kitamura wrote: > > Almost ...
4 years, 1 month ago (2016-11-21 09:02:35 UTC) #32
Yuta Kitamura
Okay, most of the changes seems reasonable. (I retract my previous NOT L-G-T-M here.) But ...
4 years, 1 month ago (2016-11-21 09:26:12 UTC) #33
Alexander Alekseev
I updated Cl description and spun off two parts of it leaving only /core/ . ...
4 years ago (2016-11-23 09:20:30 UTC) #35
mstensho (USE GERRIT)
Looks like you're moving debug dump functions over from #ifndef NDEBUG to #if DCHECK_IS_ON(). I ...
4 years ago (2016-11-29 12:06:12 UTC) #37
Alexander Alekseev
On 2016/11/29 12:06:12, mstensho wrote: > Looks like you're moving debug dump functions over from ...
4 years ago (2016-11-30 00:25:19 UTC) #38
Stephen Chennney
On 2016/11/30 00:25:19, Alexander Alekseev wrote: > On 2016/11/29 12:06:12, mstensho wrote: > > Looks ...
4 years ago (2016-11-30 00:50:42 UTC) #39
Alexander Alekseev
On 2016/11/30 00:50:42, Stephen Chennney wrote: > On 2016/11/30 00:25:19, Alexander Alekseev wrote: > > ...
4 years ago (2016-11-30 02:56:08 UTC) #40
mstensho (USE GERRIT)
https://codereview.chromium.org/2513893002/diff/160001/third_party/WebKit/Source/core/layout/LayoutObject.cpp File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): https://codereview.chromium.org/2513893002/diff/160001/third_party/WebKit/Source/core/layout/LayoutObject.cpp#newcode35 third_party/WebKit/Source/core/layout/LayoutObject.cpp:35: #include "core/dom/Node.h" No need for this. It's quite evident ...
4 years ago (2016-11-30 10:00:13 UTC) #47
Alexander Alekseev
https://codereview.chromium.org/2513893002/diff/160001/third_party/WebKit/Source/core/layout/LayoutObject.cpp File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): https://codereview.chromium.org/2513893002/diff/160001/third_party/WebKit/Source/core/layout/LayoutObject.cpp#newcode35 third_party/WebKit/Source/core/layout/LayoutObject.cpp:35: #include "core/dom/Node.h" On 2016/11/30 10:00:13, mstensho wrote: > No ...
4 years ago (2016-12-01 06:05:14 UTC) #50
mstensho (USE GERRIT)
lgtm
4 years ago (2016-12-01 07:44:20 UTC) #51
Yuta Kitamura
Looks good except for the #ifndef block change noted below. LGTM if the #ifndef block ...
4 years ago (2016-12-01 08:18:57 UTC) #54
mstensho (USE GERRIT)
https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h#newcode325 third_party/WebKit/Source/core/layout/LayoutObject.h:325: if (paintInvalidationStateIsDirty()) { On 2016/12/01 08:18:56, Yuta Kitamura wrote: ...
4 years ago (2016-12-01 08:29:21 UTC) #55
Alexander Alekseev
https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h#newcode325 third_party/WebKit/Source/core/layout/LayoutObject.h:325: if (paintInvalidationStateIsDirty()) { On 2016/12/01 08:29:21, mstensho wrote: > ...
4 years ago (2016-12-01 08:54:39 UTC) #56
Yuta Kitamura
[The last conditional L-G-T-M still holds.] https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h#newcode325 third_party/WebKit/Source/core/layout/LayoutObject.h:325: if (paintInvalidationStateIsDirty()) { ...
4 years ago (2016-12-01 09:51:06 UTC) #59
mstensho (USE GERRIT)
https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h#newcode325 third_party/WebKit/Source/core/layout/LayoutObject.h:325: if (paintInvalidationStateIsDirty()) { On 2016/12/01 09:51:06, Yuta Kitamura wrote: ...
4 years ago (2016-12-01 10:00:37 UTC) #60
Yuta Kitamura
https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h#newcode325 third_party/WebKit/Source/core/layout/LayoutObject.h:325: if (paintInvalidationStateIsDirty()) { On 2016/12/01 10:00:37, mstensho wrote: > ...
4 years ago (2016-12-01 10:56:51 UTC) #61
mstensho (USE GERRIT)
https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h#newcode325 third_party/WebKit/Source/core/layout/LayoutObject.h:325: if (paintInvalidationStateIsDirty()) { On 2016/12/01 10:56:50, Yuta Kitamura wrote: ...
4 years ago (2016-12-01 12:44:10 UTC) #62
Alexander Alekseev
https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2513893002/diff/180001/third_party/WebKit/Source/core/layout/LayoutObject.h#newcode325 third_party/WebKit/Source/core/layout/LayoutObject.h:325: if (paintInvalidationStateIsDirty()) { On 2016/12/01 12:44:10, mstensho wrote: > ...
4 years ago (2016-12-02 03:39:31 UTC) #63
Alexander Alekseev
I removed the questionable block from this CL and I am going to land this. ...
4 years ago (2016-12-02 03:42:20 UTC) #64
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2513893002/200001
4 years ago (2016-12-02 05:45:52 UTC) #71
commit-bot: I haz the power
Committed patchset #11 (id:200001)
4 years ago (2016-12-02 05:50:13 UTC) #74
commit-bot: I haz the power
4 years ago (2016-12-02 05:52:39 UTC) #76
Message was sent while issue was closed.
Patchset 11 (id:??) landed as
https://crrev.com/5dd87e237131833c489f0b3ce5b231526318b37c
Cr-Commit-Position: refs/heads/master@{#435865}

Powered by Google App Engine
This is Rietveld 408576698