Bug 175211 - [WTF] Move TextStream into WTF
Summary: [WTF] Move TextStream into WTF
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Template Framework (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2017-08-04 14:30 PDT by Don Olmstead
Modified: 2017-08-10 15:08 PDT (History)
10 users (show)

See Also:


Attachments
Patch just namespace change (295.63 KB, patch)
2017-08-04 14:38 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
Patch just namespace change (295.64 KB, patch)
2017-08-04 15:19 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
WIP Patch (21.41 KB, patch)
2017-08-07 14:28 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
WIP Patch (277.90 KB, application/x-director)
2017-08-07 17:25 PDT, Don Olmstead
no flags Details
WIP Patch (135.58 KB, patch)
2017-08-07 17:26 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
WIP patch (136.41 KB, patch)
2017-08-07 17:54 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
Patch (195.02 KB, patch)
2017-08-08 18:07 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
Patch (195.04 KB, patch)
2017-08-08 18:45 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
Patch (191.91 KB, patch)
2017-08-08 19:39 PDT, Don Olmstead
buildbot: commit-queue-
Details | Formatted Diff | Diff
Archive of layout-test-results from ews100 for mac-elcapitan (1.78 MB, application/zip)
2017-08-08 21:01 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews105 for mac-elcapitan-wk2 (1.88 MB, application/zip)
2017-08-08 21:05 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews115 for mac-elcapitan (2.57 MB, application/zip)
2017-08-08 21:23 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews123 for ios-simulator-wk2 (1.56 MB, application/zip)
2017-08-08 22:54 PDT, Build Bot
no flags Details
Patch (384.95 KB, patch)
2017-08-09 14:51 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
Patch (384.95 KB, patch)
2017-08-09 14:53 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
Patch (192.47 KB, patch)
2017-08-09 14:55 PDT, Don Olmstead
no flags Details | Formatted Diff | Diff
Fix for iOS build (1.46 KB, patch)
2017-08-10 14:14 PDT, Ross Kirsling
mmaxfield: review+
mmaxfield: commit-queue-
Details | Formatted Diff | Diff
Fix for iOS build (2.10 KB, patch)
2017-08-10 14:28 PDT, Ross Kirsling
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Don Olmstead 2017-08-04 14:30:31 PDT
Move TextStream into PAL.
Comment 1 Sam Weinig 2017-08-04 14:36:48 PDT
Since TextStream does not abstract any platform, I'm not sure PAL is the right place for it. Seems like WTF would be a better fit.
Comment 2 Don Olmstead 2017-08-04 14:38:01 PDT
Created attachment 317291 [details]
Patch just namespace change

Throwing at the bots before moving TextStream.h/cpp
Comment 3 Build Bot 2017-08-04 14:42:20 PDT
Attachment 317291 [details] did not pass style-queue:


ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:101:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:102:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:103:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:112:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:113:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:114:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:311:  Boolean expressions that span multiple lines should have their operators on the left side of the line instead of the right side.  [whitespace/operators] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:311:  Tests for true/false, null/non-null, and zero/non-zero should all be done without equality comparisons.  [readability/comparison_to_zero] [5]
ERROR: Tools/TestWebKitAPI/Tests/WebCore/CalculationValue.cpp:32:  Inner-style forward declarations are invalid.  Remove this line.  [build/forward_decl] [5]
Total errors found: 9 in 232 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 4 Don Olmstead 2017-08-04 15:19:23 PDT
Created attachment 317300 [details]
Patch just namespace change

Hopefully fixing xcode builds
Comment 5 Build Bot 2017-08-04 15:21:59 PDT
Attachment 317300 [details] did not pass style-queue:


ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:101:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:102:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:103:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:112:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:113:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:114:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:311:  Boolean expressions that span multiple lines should have their operators on the left side of the line instead of the right side.  [whitespace/operators] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:311:  Tests for true/false, null/non-null, and zero/non-zero should all be done without equality comparisons.  [readability/comparison_to_zero] [5]
Total errors found: 8 in 232 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 6 Don Olmstead 2017-08-04 15:25:05 PDT
(In reply to Sam Weinig from comment #1)
> Since TextStream does not abstract any platform, I'm not sure PAL is the
> right place for it. Seems like WTF would be a better fit.

Doh missed this comment before making the patch. I can move it into WTF instead if you feel that's a better choice. Might make the patch less massive in the end.
Comment 7 Myles C. Maxfield 2017-08-04 22:34:28 PDT
WTF is fine with me. Sorry for the bad direction.
Comment 8 Don Olmstead 2017-08-07 12:49:57 PDT
Updating summary for new game plan
Comment 9 Don Olmstead 2017-08-07 14:28:21 PDT
Created attachment 317468 [details]
WIP Patch

Replaced forward declarations with an include. Wanted to see if this is the way to go forward with this before continuing the move. Also wanted to verify this builds outside of WinCairo.

Expecting the style checker to fail as I have not ordered the includes properly in this.
Comment 10 Build Bot 2017-08-07 14:32:57 PDT
Attachment 317468 [details] did not pass style-queue:


ERROR: Source/WebCore/page/scrolling/ScrollingStateNode.h:36:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/rendering/style/RenderStyleConstants.h:29:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/displaylists/DisplayListItems.h:38:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/page/scrolling/ScrollingCoordinator.h:37:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/Color.h:38:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/FloatSize.h:32:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/IntSize.h:30:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/IntPoint.h:30:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/GraphicsLayer.h:42:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/rendering/RenderTreeAsText.h:29:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/CalculationValue.h:38:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/Length.h:32:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/dom/Position.h:33:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/FloatPoint.h:32:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/Path.h:37:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/filters/LightSource.h:29:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/LayoutRect.h:38:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/LayoutUnit.h:40:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/animation/TimingFunction.h:29:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/FontTaggedSettings.h:32:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/transforms/AffineTransform.h:34:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/filters/FilterEffect.h:33:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/GraphicsTypes.h:31:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/displaylists/DisplayList.h:33:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:34:  Bad include order. Mixing system and custom headers.  [build/include_order] [4]
Total errors found: 25 in 33 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 11 Don Olmstead 2017-08-07 17:25:59 PDT
Created attachment 317519 [details]
WIP Patch

Just moving the namespace. Is building in WinCairo. Seeing what happens with the bots.

Some formatting changes snuck in due to trailing spaces the IDE caught...
Comment 12 Don Olmstead 2017-08-07 17:26:47 PDT
Created attachment 317520 [details]
WIP Patch
Comment 13 Build Bot 2017-08-07 17:28:47 PDT
Attachment 317520 [details] did not pass style-queue:


ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:101:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:102:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:103:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:112:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:113:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:114:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:311:  Boolean expressions that span multiple lines should have their operators on the left side of the line instead of the right side.  [whitespace/operators] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:311:  Tests for true/false, null/non-null, and zero/non-zero should all be done without equality comparisons.  [readability/comparison_to_zero] [5]
Total errors found: 8 in 120 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 14 Don Olmstead 2017-08-07 17:54:09 PDT
Created attachment 317528 [details]
WIP patch

Fixing Range compile issue on the bots
Comment 15 Build Bot 2017-08-07 18:01:02 PDT
Attachment 317528 [details] did not pass style-queue:


ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:101:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:102:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:103:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:112:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:113:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:114:  More than one command on the same line  [whitespace/newline] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:311:  Boolean expressions that span multiple lines should have their operators on the left side of the line instead of the right side.  [whitespace/operators] [4]
ERROR: Source/WebCore/platform/graphics/transforms/TransformationMatrix.h:311:  Tests for true/false, null/non-null, and zero/non-zero should all be done without equality comparisons.  [readability/comparison_to_zero] [5]
Total errors found: 8 in 121 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 16 Don Olmstead 2017-08-08 18:07:52 PDT
Created attachment 317661 [details]
Patch

xcode builds should work
Comment 17 Build Bot 2017-08-08 18:10:22 PDT
Attachment 317661 [details] did not pass style-queue:


ERROR: Source/WTF/wtf/text/TextStream.h:36:  Should be indented on a separate line, with the colon or comma first on that line.  [whitespace/indent] [4]
Total errors found: 1 in 256 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 18 Don Olmstead 2017-08-08 18:45:27 PDT
Created attachment 317663 [details]
Patch
Comment 19 Build Bot 2017-08-08 18:49:06 PDT
Attachment 317663 [details] did not pass style-queue:


ERROR: Source/WebCore/platform/Length.cpp:32:  Alphabetical sorting problem.  [build/include_order] [4]
ERROR: Source/WTF/wtf/text/TextStream.h:36:  Should be indented on a separate line, with the colon or comma first on that line.  [whitespace/indent] [4]
Total errors found: 2 in 256 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 20 Don Olmstead 2017-08-08 19:39:19 PDT
Created attachment 317666 [details]
Patch
Comment 21 Build Bot 2017-08-08 21:00:59 PDT
Comment on attachment 317666 [details]
Patch

Attachment 317666 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.webkit.org/results/4281704

New failing tests:
svg/W3C-SVG-1.1/painting-stroke-04-t.svg
svg/W3C-SVG-1.1/struct-group-03-t.svg
transforms/svg-vs-css.xhtml
svg/custom/dasharrayOrigin.svg
svg/transforms/svg-css-transforms.xhtml
svg/custom/invalid-dasharray.svg
svg/css/composite-shadow-example.html
svg/css/composite-shadow-with-opacity.html
svg/filters/subRegion-two-effects.svg
fast/repaint/moving-shadow-on-container.html
svg/filters/subRegion-one-effect.svg
svg/custom/js-repaint-rect-on-path-with-stroke.svg
svg/custom/use-css-no-effect-on-shadow-tree.svg
fast/repaint/moving-shadow-on-path.html
svg/W3C-SVG-1.1/animate-elem-33-t.svg
svg/W3C-SVG-1.1/animate-elem-78-t.svg
svg/W3C-SVG-1.1/animate-elem-41-t.svg
Comment 22 Build Bot 2017-08-08 21:01:00 PDT
Created attachment 317671 [details]
Archive of layout-test-results from ews100 for mac-elcapitan

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews100  Port: mac-elcapitan  Platform: Mac OS X 10.11.6
Comment 23 Build Bot 2017-08-08 21:05:00 PDT
Comment on attachment 317666 [details]
Patch

Attachment 317666 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.webkit.org/results/4281712

New failing tests:
svg/filters/subRegion-one-effect.svg
transforms/svg-vs-css.xhtml
svg/custom/dasharrayOrigin.svg
svg/custom/js-repaint-rect-on-path-with-stroke.svg
svg/custom/invalid-dasharray.svg
svg/css/composite-shadow-example.html
svg/css/composite-shadow-with-opacity.html
svg/filters/subRegion-two-effects.svg
fast/repaint/moving-shadow-on-container.html
svg/W3C-SVG-1.1/struct-group-03-t.svg
svg/transforms/svg-css-transforms.xhtml
svg/custom/use-css-no-effect-on-shadow-tree.svg
fast/repaint/moving-shadow-on-path.html
svg/W3C-SVG-1.1/animate-elem-78-t.svg
svg/W3C-SVG-1.1/animate-elem-33-t.svg
svg/W3C-SVG-1.1/painting-stroke-04-t.svg
svg/W3C-SVG-1.1/animate-elem-41-t.svg
Comment 24 Build Bot 2017-08-08 21:05:02 PDT
Created attachment 317672 [details]
Archive of layout-test-results from ews105 for mac-elcapitan-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews105  Port: mac-elcapitan-wk2  Platform: Mac OS X 10.11.6
Comment 25 Build Bot 2017-08-08 21:23:18 PDT
Comment on attachment 317666 [details]
Patch

Attachment 317666 [details] did not pass mac-debug-ews (mac):
Output: http://webkit-queues.webkit.org/results/4281714

New failing tests:
svg/W3C-SVG-1.1/painting-stroke-04-t.svg
svg/W3C-SVG-1.1/struct-group-03-t.svg
transforms/svg-vs-css.xhtml
svg/custom/dasharrayOrigin.svg
svg/transforms/svg-css-transforms.xhtml
svg/custom/invalid-dasharray.svg
svg/css/composite-shadow-example.html
svg/css/composite-shadow-with-opacity.html
svg/filters/subRegion-two-effects.svg
fast/repaint/moving-shadow-on-container.html
svg/filters/subRegion-one-effect.svg
svg/custom/js-repaint-rect-on-path-with-stroke.svg
svg/custom/use-css-no-effect-on-shadow-tree.svg
fast/repaint/moving-shadow-on-path.html
svg/W3C-SVG-1.1/animate-elem-33-t.svg
svg/W3C-SVG-1.1/animate-elem-78-t.svg
svg/W3C-SVG-1.1/animate-elem-41-t.svg
Comment 26 Build Bot 2017-08-08 21:23:19 PDT
Created attachment 317675 [details]
Archive of layout-test-results from ews115 for mac-elcapitan

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews115  Port: mac-elcapitan  Platform: Mac OS X 10.11.6
Comment 27 Build Bot 2017-08-08 22:54:14 PDT
Comment on attachment 317666 [details]
Patch

Attachment 317666 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: http://webkit-queues.webkit.org/results/4282059

New failing tests:
svg/W3C-SVG-1.1/painting-stroke-04-t.svg
svg/W3C-SVG-1.1/struct-group-03-t.svg
transforms/svg-vs-css.xhtml
svg/custom/dasharrayOrigin.svg
svg/custom/invalid-dasharray.svg
svg/filters/subRegion-two-effects.svg
svg/filters/subRegion-one-effect.svg
svg/custom/js-repaint-rect-on-path-with-stroke.svg
svg/custom/use-css-no-effect-on-shadow-tree.svg
svg/W3C-SVG-1.1/animate-elem-78-t.svg
Comment 28 Build Bot 2017-08-08 22:54:15 PDT
Created attachment 317678 [details]
Archive of layout-test-results from ews123 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews123  Port: ios-simulator-wk2  Platform: Mac OS X 10.12.5
Comment 29 Don Olmstead 2017-08-09 10:45:04 PDT
Comment on attachment 317666 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=317666&action=review

Those changes were required to get it compiled out. Since this was a straight copy of the file those changes didn't really make sense.

Investigating now.

> Source/WebCore/platform/graphics/displaylists/DisplayList.cpp:41
> +    ts << this;

This change I also found weird.

> Source/WebCore/rendering/svg/SVGRenderTreeAsText.cpp:-142
> -

Removing this turned the dash array declaration from [dash array={..}] to [dash array=[..]].
Comment 30 Don Olmstead 2017-08-09 14:51:32 PDT
Created attachment 317746 [details]
Patch
Comment 31 Don Olmstead 2017-08-09 14:53:38 PDT
Created attachment 317747 [details]
Patch
Comment 32 Don Olmstead 2017-08-09 14:55:29 PDT
Created attachment 317748 [details]
Patch
Comment 33 Don Olmstead 2017-08-09 15:45:21 PDT
Comment on attachment 317748 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=317748&action=review

Bots that were failing are coming back as green so I think this is good to review.

> Source/WebCore/rendering/svg/SVGRenderTreeAsText.cpp:104
> +

If this isn't moved Clang comes back with an error for an unused function. Since DashArray is a typedef of a Vector it chooses Vector's operator << rather than the specialized one. Moving it before writeNameValuePair rectifies this.
Comment 34 Myles C. Maxfield 2017-08-09 17:18:52 PDT
Comment on attachment 317748 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=317748&action=review

I'm not an OWNER of the WebKit subproject, but just the change in pathnames shouldn't require an OWNER. Aside from the "WTF::", it looks good to me.

> Source/WebCore/dom/ViewportArguments.h:148
> +WTF::TextStream& operator<<(WTF::TextStream&, const ViewportArguments&);

The WTF style is to say "using WTF::Foo;" at the bottom of WTF headers. Doing this means you don't need "WTF::" sprayed over WebCore.

We chose a different style for PAL, and for now, we should keep the two styles different. We may wish to change the style for WTF some time in the future, but it should be its own discussion.
Comment 35 Don Olmstead 2017-08-09 17:34:19 PDT
Comment on attachment 317748 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=317748&action=review

>> Source/WebCore/dom/ViewportArguments.h:148
>> +WTF::TextStream& operator<<(WTF::TextStream&, const ViewportArguments&);
> 
> The WTF style is to say "using WTF::Foo;" at the bottom of WTF headers. Doing this means you don't need "WTF::" sprayed over WebCore.
> 
> We chose a different style for PAL, and for now, we should keep the two styles different. We may wish to change the style for WTF some time in the future, but it should be its own discussion.

With TextStream there were a lot of header files where it was forward declared. In those cases I moved the forward declaration into a WTF namespace within the header. There is a using declaration within TextStream to put it into a global scope. That's why there are only WTF::TextStream usages within header files but not within source files.

So in cases like this should it be forward declared without a namespace?

Just making sure since I'll have to rework the headers here.
Comment 36 Myles C. Maxfield 2017-08-09 17:37:53 PDT
(In reply to Don Olmstead from comment #35)
> With TextStream there were a lot of header files where it was forward
> declared. In those cases I moved the forward declaration into a WTF
> namespace within the header.

This is the right thing to do.
Comment 37 Don Olmstead 2017-08-09 17:38:59 PDT
(In reply to Myles C. Maxfield from comment #36)
> (In reply to Don Olmstead from comment #35)
> > With TextStream there were a lot of header files where it was forward
> > declared. In those cases I moved the forward declaration into a WTF
> > namespace within the header.
> 
> This is the right thing to do.

Then we good to go? :)
Comment 38 Myles C. Maxfield 2017-08-09 17:41:35 PDT
(In reply to Don Olmstead from comment #37)
> (In reply to Myles C. Maxfield from comment #36)
> > (In reply to Don Olmstead from comment #35)
> > > With TextStream there were a lot of header files where it was forward
> > > declared. In those cases I moved the forward declaration into a WTF
> > > namespace within the header.
> > 
> > This is the right thing to do.
> 
> Then we good to go? :)

Sorry, I misunderstood you. You're stating "WTF::" only in headers which forward-declare the WTF type.

I think this is okay.
Comment 39 WebKit Commit Bot 2017-08-09 18:15:20 PDT
Comment on attachment 317748 [details]
Patch

Clearing flags on attachment: 317748

Committed r220503: <http://trac.webkit.org/changeset/220503>
Comment 40 WebKit Commit Bot 2017-08-09 18:15:23 PDT
All reviewed patches have been landed.  Closing bug.
Comment 41 Radar WebKit Bug Importer 2017-08-09 18:16:35 PDT
<rdar://problem/33817318>
Comment 42 Ryan Haddad 2017-08-10 08:40:43 PDT
(In reply to WebKit Commit Bot from comment #39)
> Comment on attachment 317748 [details]
> Patch
> 
> Clearing flags on attachment: 317748
> 
> Committed r220503: <http://trac.webkit.org/changeset/220503>
This change broke the iOS Debug build:
https://build.webkit.org/builders/Apple%20iOS%2010%20Simulator%20Debug%20%28Build%29/builds/4106
Comment 43 Ryan Haddad 2017-08-10 09:38:10 PDT
(In reply to Ryan Haddad from comment #42)
> (In reply to WebKit Commit Bot from comment #39)
> > Comment on attachment 317748 [details]
> > Patch
> > 
> > Clearing flags on attachment: 317748
> > 
> > Committed r220503: <http://trac.webkit.org/changeset/220503>
> This change broke the iOS Debug build:
> https://build.webkit.org/builders/
> Apple%20iOS%2010%20Simulator%20Debug%20%28Build%29/builds/4106
/Volumes/Data/slave/ios-simulator-10-debug/build/Source/WebKit/UIProcess/API/Cocoa/WKWebView.mm:1868:85: error: invalid operands to binary expression ('WTF::TextStream' and 'CGPoint')
/Volumes/Data/slave/ios-simulator-10-debug/build/Source/WebKit/UIProcess/API/Cocoa/WKWebView.mm:2682:104: error: invalid operands to binary expression ('WTF::TextStream' and 'CGRect')
Comment 44 Don Olmstead 2017-08-10 10:48:02 PDT
(In reply to Ryan Haddad from comment #42)
> (In reply to WebKit Commit Bot from comment #39)
> > Comment on attachment 317748 [details]
> > Patch
> > 
> > Clearing flags on attachment: 317748
> > 
> > Committed r220503: <http://trac.webkit.org/changeset/220503>
> This change broke the iOS Debug build:
> https://build.webkit.org/builders/
> Apple%20iOS%2010%20Simulator%20Debug%20%28Build%29/builds/4106

Working on a fix currently.
Comment 45 Ross Kirsling 2017-08-10 14:14:29 PDT
Created attachment 317844 [details]
Fix for iOS build
Comment 46 Myles C. Maxfield 2017-08-10 14:23:49 PDT
Comment on attachment 317844 [details]
Fix for iOS build

Please create a ChangeLog entry.
Comment 47 Ross Kirsling 2017-08-10 14:28:35 PDT
Created attachment 317847 [details]
Fix for iOS build

Resubmitted with ChangeLog.
Comment 48 Ryan Haddad 2017-08-10 15:08:38 PDT
Comment on attachment 317847 [details]
Fix for iOS build

Clearing flags on attachment: 317847

Committed r220550: <http://trac.webkit.org/changeset/220550>
Comment 49 Ryan Haddad 2017-08-10 15:08:40 PDT
All reviewed patches have been landed.  Closing bug.