Open Bug 903843 (iwyu) Opened 11 years ago Updated 2 months ago

Use include-what-you-use (iwyu)

Categories

(Developer Infrastructure :: Source Code Analysis, enhancement, P3)

enhancement

Tracking

(Not tracked)

People

(Reporter: Ms2ger, Unassigned)

References

(Depends on 2 open bugs, )

Details

Attachments

(1 file)

      No description provided.
Alias: iwyu
Depends on: 903844
Attached file fix_includes.py
To set up iwyu, I found <http://code.google.com/p/include-what-you-use/wiki/InstructionsForUsers> clear enough. (I used "Building in-tree".)

I made a few changes to the fix_includes.py script; the result is attached.
Depends on: 910160
Depends on: 915466
Component: Tracking → General
QA Contact: chofmann
Component: General → Rewriting and Analysis
Would it be a good idea to get a tool like this integrated into our clang plugin to vocally complain when you include things you don't use? I'm worried that it won't work nicely with our unified builds.
Product: Core → Firefox Build System
Severity: normal → enhancement
Priority: -- → P3
Depends on: 1485674

Periodically, individuals run IWYU against the tree. For example, I see that :botond did this in tickets like https://bugzilla.mozilla.org/show_bug.cgi?id=1605466 and :sg did a large pass recently in tickets rooted at https://bugzilla.mozilla.org/show_bug.cgi?id=1676346.

In the years since this ticket was filed, it's become much easier to write and run custom linters and we've invested heavily into clang-based tooling. Perhaps the time is now for running IWYU in automation...

My specific use case is that I'd like to be able to visualize what includes a certain file (in my case, xptdata.h) without configuring IWYU myself.

:nalexander, there is bug 1682477 about integrating IWYU in the review bot.

See Also: → 1682477
Depends on: 1754864
See Also: → 1772757
Product: Firefox Build System → Developer Infrastructure
Severity: normal → S3
See Also: → 1840732
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: