[webkit-dev] Checking include paths in WebCore for bad dependencies

Darin Adler darin at apple.com
Mon Nov 8 11:55:41 PST 2010


On Nov 8, 2010, at 11:47 AM, James Robinson wrote:

> For example, WebCore/platform is intended to be a base component that the rest of WebCore can depend on but that should not have any outward dependencies.

In JavaScriptCore we have the same thing with JavaScriptCore/wtf and the rest of JavaScriptCore.

> Making bad includes show up when running check-webkit-style and in the style-ews will make these bad includes more visible and hopefully help people fix them. There's an initial patch up at https://bugs.webkit.org/show_bug.cgi?id=49192.

Sounds like a good idea.

> Additionally, I'd like to use this tool to try to create and enforce some more boundaries and one-way dependencies within WebCore.

We should discuss any specific ideas for this we have to see if they are promising. I would not assume there are great opportunities for this, but there may be some. I wouldn’t want to rearrange code a lot to accomplish this because there’s no guarantee that it would make things easier to understand or modify.

At one time, the C++ bindings in WebCore inherited from khtml had this issue. They were supposed to be a binding layer on top of the DOM but they were used elsewhere. We resolved that and then later removed the C++ bindings.

    -- Darin



More information about the webkit-dev mailing list