mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-07-11 22:03:01 -06:00
ide: Fixed C++ parser include issue
git-svn-id: svn://ultimatepp.org/upp/trunk@14661 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
9b3a6a570d
commit
15122bc026
3 changed files with 9 additions and 4 deletions
|
|
@ -456,6 +456,7 @@ String GetIncludePath(const String& s, const String& filedir)
|
|||
|
||||
void MakePP(const Index<String>& paths)
|
||||
{
|
||||
LLOG("MakePP " << paths);
|
||||
Vector<String> todo;
|
||||
Vector<PPFile *> pp;
|
||||
for(int i = 0; i < paths.GetCount(); i++) {
|
||||
|
|
@ -477,6 +478,7 @@ void MakePP(const Index<String>& paths)
|
|||
const PPFile& GetPPFile(const char *path)
|
||||
{
|
||||
LTIMING("GetPPFile");
|
||||
LLOG("GetPPFile " << path);
|
||||
static PPFile zero;
|
||||
return sPPfile.Get(path, zero);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
namespace Upp {
|
||||
|
||||
#define LTIMING(x) // DTIMING(x)
|
||||
#define LLOG(x) // DLOG(x)
|
||||
|
||||
static VectorMap<String, String> sSrcFile;
|
||||
static Index<uint64> sIncludes;
|
||||
|
|
@ -42,6 +43,7 @@ const VectorMap<String, String>& GetAllSourceMasters()
|
|||
void GatherSources(const String& master_path, const String& path_, Vector<int>& parents)
|
||||
{
|
||||
String path = NormalizeSourcePath(path_);
|
||||
LLOG("--- GatherSources " << master_path << " " << path);
|
||||
if(sSrcFile.Find(path) >= 0)
|
||||
return;
|
||||
int ii = sSrcFile.GetCount();
|
||||
|
|
@ -51,8 +53,8 @@ void GatherSources(const String& master_path, const String& path_, Vector<int>&
|
|||
parents.Add(ii);
|
||||
const PPFile& f = GetPPFile(path);
|
||||
Index<String> todo;
|
||||
for(int i = 0; i < f.includes.GetCount(); i++) {
|
||||
String p = GetIncludePath(f.includes[i], GetFileFolder(path));
|
||||
for(String inc : f.includes) {
|
||||
String p = GetIncludePath(inc, GetFileFolder(path));
|
||||
if(p.GetCount())
|
||||
todo.FindAdd(p);
|
||||
}
|
||||
|
|
@ -66,7 +68,8 @@ void GatherSources(const String& path)
|
|||
{
|
||||
LTIMING("GatherSources");
|
||||
Vector<int> parents;
|
||||
MakePP({ path });
|
||||
LLOG("=== GatherSources " << path);
|
||||
MakePP({ NormalizeSourcePath(path) });
|
||||
GatherSources(NormalizeSourcePath(path), path, parents);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -242,7 +242,7 @@ void BaseInfoSync(Progress& pi)
|
|||
pi.SetText("Gathering files");
|
||||
pi.SetTotal(wspc.GetCount());
|
||||
|
||||
for(int pass = 0; pass < 2; pass++)
|
||||
for(int pass = 0; pass < 2; pass++) // Ignore headers in the first pass to get correct master files
|
||||
for(int i = 0; i < wspc.GetCount(); i++) {
|
||||
pi.Step();
|
||||
const Package& pk = wspc.GetPackage(i);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue