Commit Graph

1 Commits

Author SHA1 Message Date
Frederich Munch
2142853de6 Don't call clang::ApplyHeaderSearchOptions from Interpreter::AddIncludePaths.
Instead call it at the end of cling::createCI (that should probably change too).

clang::ApplyHeaderSearchOptions is a very heavy-weight function that does a lot
of work to determine and add system headers. More importantly it can also wind
up invalidating clangs internal cache making inclusion of files later impossible.

By using the lighter HeaderSearchOptions::AddSearchPath we not only avoid redoing
a lot of work that has been done, but can adjust the method in clang to avoid
cache invalidation so that calling Interpreter::AddIncludePath will actually
make the files in that path accessible to clang.

Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-08-18 15:44:18 +02:00