Re: [webkit-dev] Unified sources have broken our #include hygiene

2018-09-01 Thread Darin Adler
> On Sep 1, 2018, at 5:14 PM, Simon Fraser  wrote:
> 
> Unified sources allow you to get away without #including all the files you 
> need in a .cpp file, because some earlier file in the group has probably 
> already included them for you.
> 
> This means that when you add a new file to the build, and the unified sources 
> get shuffled around, you end up with a long list of build breakages, some 
> platform-specific, that you can only fix by repeating EWS trials.

Yes.

We knew this was going to happen when evaluated the proposal before we switched 
to unified sources. I believe you can find some discussion of it in webkit-dev.

> How can we solve this?

I don’t think we should try to solve it.

To me at the moment, this seems to be a minor irritation. Even without unified 
sources, it’s common to get includes wrong for platforms other than the one you 
are testing on and find this out only when building on EWS.

I would be OK having an EWS server that builds various platforms without 
unified sources, but while it might help it might also hurt, adding more EWS 
results to interpret for each patch, and also finding theoretical problems that 
don’t affect any platform.

If there’s a tool that can figure out what files need to be included by 
analyzing source code, and that works well enough to be practical, I’d love to 
arrange it so that we can use that instead of having programmers have to write 
their own include statements. I’ve long been interested in 
> and 
wondered whether we could use it, but it sort of does the opposite, and the 
“multiple platforms” problem could well make even that tool impractical for us.

— Darin___
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev


Re: [webkit-dev] Unified sources have broken our #include hygiene

2018-09-01 Thread Tim Horton



> On Sep 1, 2018, at 17:14, Simon Fraser  wrote:
> 
> Unified sources allow you to get away without #including all the files you 
> need in a .cpp file, because some earlier file in the group has probably 
> already included them for you.
> 
> This means that when you add a new file to the build, and the unified sources 
> get shuffled around, you end up with a long list of build breakages, some 
> platform-specific, that you can only fix by repeating EWS trials. Here's an 
> example: https://bugs.webkit.org/show_bug.cgi?id=189223. That patch added on 
> new file in Source/WebCore/rendering, which required unrelated #include 
> changes in at least:
> 
> rendering/RenderBlockFlow.cpp:
> rendering/RenderFrame.cpp:
> rendering/RenderImage.cpp:
> 
> How can we solve this? Should we have an EWS that builds non-unified?

Yes!

> Can we somehow have the style checker do #include enforcement?

Certainly not the style checker we have now!

> Simon
> 
> ___
> webkit-dev mailing list
> webkit-dev@lists.webkit.org
> https://lists.webkit.org/mailman/listinfo/webkit-dev
___
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev


[webkit-dev] Unified sources have broken our #include hygiene

2018-09-01 Thread Simon Fraser
Unified sources allow you to get away without #including all the files you need 
in a .cpp file, because some earlier file in the group has probably already 
included them for you.

This means that when you add a new file to the build, and the unified sources 
get shuffled around, you end up with a long list of build breakages, some 
platform-specific, that you can only fix by repeating EWS trials. Here's an 
example: https://bugs.webkit.org/show_bug.cgi?id=189223. That patch added on 
new file in Source/WebCore/rendering, which required unrelated #include changes 
in at least:

rendering/RenderBlockFlow.cpp:
rendering/RenderFrame.cpp:
rendering/RenderImage.cpp:

How can we solve this? Should we have an EWS that builds non-unified? Can we 
somehow have the style checker do #include enforcement?

Simon

___
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev