[cfe-dev] Suggestion for improving #include error message

Christian Adåker cadaker at gmail.com
Thu Oct 29 06:45:34 PDT 2009


On Thu, Oct 29, 2009 at 1:53 PM, Renato Golin <rengolin at systemcall.org> wrote:
> However, there could be a separate tool, to find headers on your
> system given your configuration and compilation options, which IDEs
> could run upon "file not found" errors. Or maybe a '-vv' mode that
> would print lots of warnings, debug information that IDEs could parse
> and do intelligent stuff with it.

I'm new to clang too, but as far as I can see clang already has an
option -print-search-dirs that shows the search paths for programs and
libraries.

This could perhaps be extended to show include paths as well? (Or, if
gcc compatibility is an issue, maybe a new option
-print-include-dirs.)

I'm not sure that the #include compiler error needs to be more
informative, but if it should, it could instead mention
-print-search-dirs. That would be less cluttered, but still give a
hint.

//Christian



More information about the cfe-dev mailing list