38 if( pos == string::npos || (
line[pos] !=
'<' &&
line[pos] !=
'\"') )
40 const char end = (
line[pos] ==
'<') ?
'>' :
'\"';
41 string::size_type pos2 =
line.find(
end,pos+1);
42 if( pos2 == string::npos || pos2 == pos+1 )
44 if(
line.length() > pos2 &&
48 incfile =
line.substr(pos+1,pos2-pos-1);
58 vector<TString> paths;
59 paths.emplace_back(incfile.c_str() );
63 unique_ptr<TObjArray> incdirs( incp.
Tokenize(
":") );
64 if( !incdirs->IsEmpty() ) {
65 Int_t ndirs = incdirs->GetLast()+1;
67 for(
Int_t i = 0; i < ndirs; ++i ) {
73 path.
Append( incfile.c_str() );
74 paths.emplace_back(path.
Data() );
79 for(
auto& path : paths ) {
82 incfile = path.
Data();
R__EXTERN TSystem * gSystem
Bool_t EndsWith(const char *pat, ECaseCompare cmp=kExact) const
const char * Data() const
TObjArray * Tokenize(const TString &delim) const
TString & Append(char c, Ssiz_t rep=1)
virtual const char * Getenv(const char *env)
virtual Bool_t AccessPathName(const char *path, EAccessMode mode=kFileExists)
virtual char * ExpandPathName(const char *path)
Int_t CheckIncludeFilePath(string &incfile)
Int_t GetIncludeFileName(const string &line, string &incfile)