HaveF / include-what-you-use

Automatically exported from code.google.com/p/include-what-you-use
Other
0 stars 0 forks source link

iwyu suggests too much to add (nested type) #135

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
//Example:
//vec_test.cc:
#include "myvec.h"
int main() {
    myvec v; //is fine
    myvec::const_iterator p; //causes iwyu to claim vector is needed
}
//cat myvec.h
#include <vector>
typedef std::vector<int> myvec;

Seems related to issue 105 and issue 111. I added this example as a new issue 
because 111 is explicit about operators.

Original issue reported on code.google.com by rol...@rschulz.eu on 28 May 2014 at 6:33

GoogleCodeExporter commented 9 years ago
I can't reproduce this with IWYU@HEAD on Windows.

Can you run IWYU with -Xiwyu --verbose=7 and attach the output to this issue? 
Maybe there's something in your standard lib implementation that throws IWYU 
off.

Original comment by kim.gras...@gmail.com on 28 May 2014 at 5:59

GoogleCodeExporter commented 9 years ago
I get the same result with the version for 3.4 and HEAD. Attached output is 
HEAD.

Original comment by rol...@rschulz.eu on 29 May 2014 at 1:30

Attachments:

GoogleCodeExporter commented 9 years ago
If I use libc++ instead of libstdc++-4.8 I don't see the problem.

Original comment by rol...@rschulz.eu on 29 May 2014 at 1:44