Commit bbd28a0f authored by Dimitri van Heesch's avatar Dimitri van Heesch

Release-1.2.11.1

parent 9e4e94fb
DOXYGEN Version 1.2.11-20011003
DOXYGEN Version 1.2.11.1
Please read the installation section of the manual for instructions.
--------
Dimitri van Heesch (03 October 2001)
Dimitri van Heesch (07 October 2001)
DOXYGEN Version 1.2.11_20011003
DOXYGEN Version 1.2.11.1
Please read INSTALL for compilation instructions.
......@@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives.
Enjoy,
Dimitri van Heesch (dimitri@stack.nl) (03 October 2001)
Dimitri van Heesch (dimitri@stack.nl) (07 October 2001)
1.2.11-20011003
1.2.11.1
Name: doxygen
Version: 1.2.11_20011003
Version: 1.2.11.1
Summary: documentation system for C, C++ and IDL
Release: 4
Source: doxygen-%{version}.src.tar.gz
......
......@@ -1192,7 +1192,10 @@ void ClassDef::writeDocumentation(OutputList &ol)
endFile(ol);
}
void ClassDef::writeDocumentationForInnerClasses(OutputList &ol)
{
// write inner classes after the parent, so the tag files contain
// the definition in proper order!
if (m_innerClasses)
......
......@@ -100,6 +100,7 @@ class ClassDef : public Definition
MemberNameInfoSDict *memberNameInfoSDict() { return m_allMemberNameInfoSDict; }
void writeDocumentation(OutputList &ol);
void writeDocumentationForInnerClasses(OutputList &ol);
void writeMemberList(OutputList &ol);
void writeDeclaration(OutputList &ol,MemberDef *md,bool inGroup);
......
......@@ -21,7 +21,6 @@
* includes
*/
#include <stdio.h>
//#include <iostream.h>
#include <assert.h>
#include <ctype.h>
#include <qregexp.h>
......@@ -33,6 +32,7 @@
#include "message.h"
#include "outputlist.h"
#include "util.h"
#include "membername.h"
#define YY_NEVER_INTERACTIVE 1
......@@ -450,7 +450,7 @@ static void generateClassLink(OutputDocInterface &ol,char *clName,int *clNameLen
else
{
MemberName *mn;
if (cd==0 && (mn=Doxygen::functionNameDict[clName]))
if (cd==0 && (mn=Doxygen::functionNameSDict[clName]))
{
if (mn->count()==1)
{
......@@ -557,8 +557,8 @@ static bool getLink(const char *className,
static bool generateClassMemberLink(OutputDocInterface &ol,ClassDef *mcd,const char *memName)
{
//printf("generateClassMemberLink(%s,%s)\n",mcd->name().data(),memName);
MemberName *mmn=Doxygen::memberNameDict[memName];
//printf("generateClassMemberLink(class=%s,member=%s)\n",mcd->name().data(),memName);
MemberName *mmn=Doxygen::memberNameSDict[memName];
if (mmn)
{
MemberNameIterator mmni(*mmn);
......@@ -581,6 +581,7 @@ static bool generateClassMemberLink(OutputDocInterface &ol,ClassDef *mcd,const c
// extract class definition of the return type in order to resolve
// a->b()->c() like call chains
g_classVar = stripClassName(xmd->typeString());
//printf("g_classVar=%s->%p\n",xmd->typeString(),g_classVar);
// add usage reference
if (g_currentDefinition && g_currentMemberDef &&
......@@ -665,7 +666,7 @@ static void generateMemberLink(OutputDocInterface &ol,const char *varName,
if (vcd && vcd->isLinkable())
{
//printf("Found class %s for variable `%s'\n",g_classScope.data(),varName);
MemberName *vmn=Doxygen::memberNameDict[varName];
MemberName *vmn=Doxygen::memberNameSDict[varName];
if (vmn==0)
{
int vi;
......@@ -675,7 +676,7 @@ static void generateMemberLink(OutputDocInterface &ol,const char *varName,
{
ClassDef *jcd = getClass(vn.left(vi));
vn=vn.right(vn.length()-vi-2);
vmn=Doxygen::memberNameDict[vn];
vmn=Doxygen::memberNameSDict[vn];
//printf("Trying name `%s' scope=%s\n",vn.data(),scope.data());
if (vmn)
{
......@@ -1159,6 +1160,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
BEGIN( MemberCall );
}
<MemberCall>{SCOPETNAME}/{B}*"(" {
//printf("g_name=`%s' g_classVar=`%s'\n",g_name.data(),g_classVar?g_classVar->name().data():"<none>");
if (!g_name.isEmpty())
{
generateMemberLink(*g_code,g_name,yytext);
......@@ -1190,6 +1192,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<MemberCall>{SCOPENAME}/{B}* {
//printf("g_name=`%s' g_classVar=`%s'\n",g_name.data(),g_classVar?g_classVar->name().data():"<none>");
if (!g_name.isEmpty())
{
generateMemberLink(*g_code,g_name,yytext);
......
This diff is collapsed.
......@@ -70,10 +70,12 @@ class Doxygen
static FileNameDict *imageNameDict;
static FileNameDict *dotFileNameDict;
static QStrList tagfileList;
static MemberNameList memberNameList;
static MemberNameList functionNameList;
static MemberNameDict memberNameDict;
static MemberNameDict functionNameDict;
//static MemberNameList memberNameList;
//static MemberNameList functionNameList;
//static MemberNameDict memberNameDict;
//static MemberNameDict functionNameDict;
static MemberNameSDict memberNameSDict;
static MemberNameSDict functionNameSDict;
static FileList fileList;
static FileDict fileDict;
static ClassDef unrelatedClass;
......
......@@ -43,7 +43,7 @@ GroupDef::GroupDef(const char *df,int dl,const char *na,const char *t) :
pageDict = new PageSDict(257);
exampleDict = new PageSDict(257);
allMemberList = new MemberList;
allMemberNameInfoDict = new MemberNameInfoDict(1009);
allMemberNameInfoSDict = new MemberNameInfoSDict(17);
fileName = (QCString)"group_"+na;
setGroupTitle( t );
memberGroupList = new MemberGroupList;
......@@ -79,7 +79,7 @@ GroupDef::~GroupDef()
delete pageDict;
delete exampleDict;
delete allMemberList;
delete allMemberNameInfoDict;
delete allMemberNameInfoSDict;
delete memberGroupList;
delete memberGroupDict;
}
......@@ -170,7 +170,7 @@ void GroupDef::insertMember(MemberDef *md,bool docOnly)
{
//fprintf(stderr, "GroupDef(%s)::insertMember(%s)\n", title.data(), md->name().data());
MemberNameInfo *mni=0;
if ((mni=(*allMemberNameInfoDict)[md->name()]))
if ((mni=(*allMemberNameInfoSDict)[md->name()]))
{ // member with this name already found
MemberNameInfoIterator srcMnii(*mni);
MemberInfo *srcMi;
......@@ -189,7 +189,7 @@ void GroupDef::insertMember(MemberDef *md,bool docOnly)
{
mni = new MemberNameInfo(md->name());
mni->append(new MemberInfo(md,md->protection(),md->virtualness(),FALSE));
allMemberNameInfoDict->insert(mni->memberName(),mni);
allMemberNameInfoSDict->append(mni->memberName(),mni);
}
allMemberList->append(md);
switch(md->memberType())
......@@ -251,7 +251,7 @@ void GroupDef::insertMember(MemberDef *md,bool docOnly)
void GroupDef::removeMember(MemberDef *md)
{
// fprintf(stderr, "GroupDef(%s)::removeMember( %s )\n", title.data(), md->name().data());
MemberNameInfo *mni = allMemberNameInfoDict->find(md->name());
MemberNameInfo *mni = allMemberNameInfoSDict->find(md->name());
if (mni)
{
MemberNameInfoIterator mnii(*mni);
......@@ -266,7 +266,7 @@ void GroupDef::removeMember(MemberDef *md)
}
if( mni->isEmpty() )
{
allMemberNameInfoDict->remove(md->name());
allMemberNameInfoSDict->remove(md->name());
delete mni;
}
......
......@@ -36,7 +36,7 @@ class OutputList;
class NamespaceList;
class MemberGroupList;
class MemberGroupDict;
class MemberNameInfoDict;
class MemberNameInfoSDict;
class PageSDict;
class PageInfo;
......@@ -64,11 +64,11 @@ class GroupDef : public Definition
int countMembers() const;
bool isLinkableInProject() const
{
return hasDocumentation() && !isReference();
return !isReference();
}
bool isLinkable() const
{
return isLinkableInProject() || isReference();
return TRUE;
}
bool isASubGroup() const;
void computeAnchors();
......@@ -97,7 +97,7 @@ class GroupDef : public Definition
PageSDict *exampleDict; // list of examples in the group
MemberList *allMemberList;
MemberNameInfoDict *allMemberNameInfoDict;
MemberNameInfoSDict *allMemberNameInfoSDict;
// members in the declaration part of the documentation
MemberList decDefineMembers;
......
......@@ -943,7 +943,7 @@ void HtmlGenerator::endMemberDocName()
void HtmlGenerator::startParameterList()
{
DBG_HTML(t << "<!-- startParameterList -->" << endl;)
t << " <td class=\"md\">(&nbsp;</td>" << endl;
t << " <td class=\"md\" valign=\"top\">(&nbsp;</td>" << endl;
}
void HtmlGenerator::startParameterType(bool first)
......@@ -951,7 +951,7 @@ void HtmlGenerator::startParameterType(bool first)
if (first)
{
DBG_HTML(t << "<!-- startFirstParameterType -->" << endl;)
t << " <td class=\"md\" nowrap>";
t << " <td class=\"md\" nowrap valign=\"top\">";
}
else
{
......@@ -973,8 +973,11 @@ void HtmlGenerator::startParameterName(bool oneArgOnly)
{
DBG_HTML(t << "<!-- startParameterName -->" << endl;)
t << " <td class=\"mdname";
if (oneArgOnly) t << "1";
t << "\">&nbsp;";
if (oneArgOnly)
{
t << "1\" valign=\"top";
}
t << "\" nowrap>&nbsp;";
}
void HtmlGenerator::endParameterName(bool last,bool emptyList)
......@@ -985,8 +988,8 @@ void HtmlGenerator::endParameterName(bool last,bool emptyList)
if (emptyList)
{
t << " </td>" << endl;
t << " <td class=\"md\">)&nbsp;</td>" << endl;
t << " <td class=\"md\">";
t << " <td class=\"md\" valign=\"top\">)&nbsp;</td>" << endl;
t << " <td class=\"md\" nowrap>";
}
else
{
......
......@@ -323,7 +323,7 @@ void endFile(OutputList &ol,bool external)
//----------------------------------------------------------------------------
void writeClassTree(OutputList &ol,BaseClassList *bcl,bool hideSuper)
void writeClassTree(OutputList &ol,BaseClassList *bcl,bool hideSuper,int level)
{
HtmlHelp *htmlHelp=0;
FTVHelp *ftvHelp=0;
......@@ -347,7 +347,16 @@ void writeClassTree(OutputList &ol,BaseClassList *bcl,bool hideSuper)
{
if (!started)
{
{
// UGLY HACK!
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Latex);
if (level<6) ol.startIndexList();
ol.enableAll();
ol.disable(OutputGenerator::Latex);
ol.startItemList();
ol.popGeneratorState();
}
if (hasHtmlHelp) htmlHelp->incContentsDepth();
if (hasFtvHelp) ftvHelp->incContentsDepth();
started=TRUE;
......@@ -390,13 +399,22 @@ void writeClassTree(OutputList &ol,BaseClassList *bcl,bool hideSuper)
//printf("Class %s at %p visited=%d\n",cd->name().data(),cd,cd->visited);
bool wasVisited=cd->visited;
cd->visited=TRUE;
writeClassTree(ol,cd->subClasses(),wasVisited);
writeClassTree(ol,cd->subClasses(),wasVisited,level+1);
}
}
}
if (started)
{
{
// UGLY HACK!
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Latex);
if (level<6) ol.endIndexList();
ol.enableAll();
ol.disable(OutputGenerator::Latex);
ol.endItemList();
ol.popGeneratorState();
}
if (hasHtmlHelp) htmlHelp->decContentsDepth();
if (hasFtvHelp) ftvHelp->decContentsDepth();
}
......@@ -406,7 +424,7 @@ void writeClassTree(OutputList &ol,BaseClassList *bcl,bool hideSuper)
//----------------------------------------------------------------------------
/*! Generates HTML Help tree of classes */
void writeClassTree(BaseClassList *cl)
void writeClassTree(BaseClassList *cl,int level)
{
HtmlHelp *htmlHelp=0;
FTVHelp *ftvHelp=0;
......@@ -448,7 +466,7 @@ void writeClassTree(BaseClassList *cl)
}
if (hasChildren)
{
writeClassTree(cd->subClasses());
writeClassTree(cd->subClasses(),level+1);
}
cd->visited=TRUE;
}
......@@ -463,7 +481,7 @@ void writeClassTree(BaseClassList *cl)
//----------------------------------------------------------------------------
/*! Generates HTML Help tree of classes */
void writeClassTreeNode(ClassDef *cd,bool hasHtmlHelp,bool hasFtvHelp,bool &started)
void writeClassTreeNode(ClassDef *cd,bool hasHtmlHelp,bool hasFtvHelp,bool &started,int level)
{
if (cd->isVisibleInHierarchy() && !cd->visited)
{
......@@ -485,13 +503,13 @@ void writeClassTreeNode(ClassDef *cd,bool hasHtmlHelp,bool hasFtvHelp,bool &star
}
if (hasChildren)
{
writeClassTree(cd->subClasses());
writeClassTree(cd->subClasses(),level+1);
}
cd->visited=TRUE;
}
}
void writeClassTree(ClassList *cl)
void writeClassTree(ClassList *cl,int level)
{
bool &generateHtml = Config_getBool("GENERATE_HTML") ;
bool hasHtmlHelp = generateHtml && Config_getBool("GENERATE_HTMLHELP");
......@@ -500,11 +518,11 @@ void writeClassTree(ClassList *cl)
bool started=FALSE;
for ( ; cli.current() ; ++cli)
{
writeClassTreeNode(cli.current(),hasHtmlHelp,hasFtvHelp,started);
writeClassTreeNode(cli.current(),hasHtmlHelp,hasFtvHelp,started,level);
}
}
void writeClassTree(ClassSDict *d)
void writeClassTree(ClassSDict *d,int level)
{
bool &generateHtml = Config_getBool("GENERATE_HTML") ;
bool hasHtmlHelp = generateHtml && Config_getBool("GENERATE_HTMLHELP");
......@@ -513,7 +531,7 @@ void writeClassTree(ClassSDict *d)
bool started=FALSE;
for ( ; cli.current() ; ++cli)
{
writeClassTreeNode(cli.current(),hasHtmlHelp,hasFtvHelp,started);
writeClassTreeNode(cli.current(),hasHtmlHelp,hasFtvHelp,started,level);
}
}
......@@ -550,7 +568,16 @@ static void writeClassTreeForList(OutputList &ol,ClassSDict *cl,bool &started)
{
if (!started)
{
{
// UGLY HACK!
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Latex);
ol.startIndexList();
ol.enableAll();
ol.disable(OutputGenerator::Latex);
ol.startItemList();
ol.popGeneratorState();
}
if (hasHtmlHelp) htmlHelp->incContentsDepth();
if (hasFtvHelp) ftvHelp->incContentsDepth();
started=TRUE;
......@@ -589,7 +616,7 @@ static void writeClassTreeForList(OutputList &ol,ClassSDict *cl,bool &started)
}
if (hasChildren)
{
writeClassTree(ol,cd->subClasses(),cd->visited);
writeClassTree(ol,cd->subClasses(),cd->visited,1);
cd->visited=TRUE;
}
}
......@@ -621,7 +648,16 @@ void writeClassHierarchy(OutputList &ol)
writeClassTreeForList(ol,&Doxygen::hiddenClasses,started);
if (started)
{
{
// UGLY HACK!
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Latex);
ol.endIndexList();
ol.enableAll();
ol.disable(OutputGenerator::Latex);
ol.endItemList();
ol.popGeneratorState();
}
if (hasHtmlHelp) htmlHelp->decContentsDepth();
if (hasFtvHelp) ftvHelp->decContentsDepth();
}
......@@ -1476,8 +1512,10 @@ void writeMemberList(OutputList &ol,bool useSections)
{
bool first = TRUE;
char lastChar = 0;
MemberName *mn=Doxygen::memberNameList.first();
while (mn)
MemberNameSDict::Iterator mnli(Doxygen::memberNameSDict);
MemberName *mn=0;
for (mnli.toFirst();(mn=mnli.current());++mnli)
{
MemberDef *md=mn->first();
bool found=FALSE;
......@@ -1549,7 +1587,6 @@ void writeMemberList(OutputList &ol,bool useSections)
md=mn->prev();
}
}
mn=Doxygen::memberNameList.next();
}
ol.endItemList();
}
......@@ -1560,8 +1597,9 @@ int countClassMembers()
{
int i=0;for (i=0;i<256;i++) g_memberIndexLetterUsed[i]=FALSE;
int count=0;
MemberName *mn=Doxygen::memberNameList.first();
while (mn)
MemberNameSDict::Iterator mnli(Doxygen::memberNameSDict);
MemberName *mn=0;
for (mnli.toFirst();(mn=mnli.current());++mnli)
{
MemberDef *md=mn->first();
bool found=FALSE;
......@@ -1584,7 +1622,6 @@ int countClassMembers()
if (!n.isEmpty()) g_memberIndexLetterUsed[tolower(n.at(0))]=TRUE;
count++;
}
mn=Doxygen::memberNameList.next();
}
return count;
}
......@@ -1661,8 +1698,9 @@ void writeFileMemberList(OutputList &ol,bool useSections)
{
char lastChar=0;
bool first=TRUE;
MemberName *mn=Doxygen::functionNameList.first();
while (mn)
MemberNameSDict::Iterator mnli(Doxygen::functionNameSDict);
MemberName *mn=0;
for (mnli.toFirst();(mn=mnli.current());++mnli)
{
MemberDef *md=mn->first();
bool found=FALSE;
......@@ -1732,7 +1770,6 @@ void writeFileMemberList(OutputList &ol,bool useSections)
md=mn->prev();
}
}
mn=Doxygen::functionNameList.next();
}
ol.endItemList();
}
......@@ -1743,8 +1780,9 @@ void writeNamespaceMemberList(OutputList &ol,bool useSections)
{
char lastChar=0;
bool first=TRUE;
MemberName *mn=Doxygen::functionNameList.first();
while (mn)
MemberNameSDict::Iterator mnli(Doxygen::functionNameSDict);
MemberName *mn=0;
for (mnli.toFirst();(mn=mnli.current());++mnli)
{
MemberDef *md=mn->first();
bool found=FALSE;
......@@ -1807,7 +1845,6 @@ void writeNamespaceMemberList(OutputList &ol,bool useSections)
md=mn->prev();
}
}
mn=Doxygen::functionNameList.next();
}
if (!first) ol.endItemList();
}
......@@ -1818,8 +1855,9 @@ int countNamespaceMembers()
{
int i=0;for (i=0;i<256;i++) g_namespaceIndexLetterUsed[i]=FALSE;
int count=0;
MemberName *mn=Doxygen::functionNameList.first();
while (mn)
MemberNameSDict::Iterator mnli(Doxygen::functionNameSDict);
MemberName *mn=0;
for (mnli.toFirst();(mn=mnli.current());++mnli)
{
MemberDef *md=mn->first();
bool found=FALSE;
......@@ -1836,7 +1874,6 @@ int countNamespaceMembers()
md=mn->next();
}
if (found) count++;
mn=Doxygen::functionNameList.next();
}
return count;
}
......@@ -1847,8 +1884,9 @@ int countFileMembers()
{
int i=0;for (i=0;i<256;i++) g_fileIndexLetterUsed[i]=FALSE;
int count=0;
MemberName *mn=Doxygen::functionNameList.first();
while (mn)
MemberNameSDict::Iterator mnli(Doxygen::functionNameSDict);
MemberName *mn=0;
for (mnli.toFirst();(mn=mnli.current());++mnli)
{
MemberDef *md=mn->first();
FileDef *fd;
......@@ -1868,7 +1906,6 @@ int countFileMembers()
md=mn->next();
}
if (found) count++;
mn=Doxygen::functionNameList.next();
}
return count;
}
......@@ -2398,7 +2435,7 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
ftvHelp->incContentsDepth();
}
writeClassTree(gd->classSDict);
writeClassTree(gd->classSDict,1);
if(htmlHelp) htmlHelp->decContentsDepth();
if(ftvHelp) ftvHelp->decContentsDepth();
}
......
......@@ -26,6 +26,7 @@
#include "language.h"
#include "scanner.h"
#include "groupdef.h"
#include "doxygen.h"
//static QCString idToName(int id)
//{
......
......@@ -71,6 +71,8 @@ MemberNameIterator::MemberNameIterator(const MemberName &mnlist) :
{
}
#if 0
MemberNameList::MemberNameList() : QList<MemberName>()
{
}
......@@ -91,3 +93,12 @@ MemberNameListIterator::MemberNameListIterator(const MemberNameList &mnlist) :
{
}
#endif
int MemberNameSDict::compareItems(GCI item1, GCI item2)
{
MemberName *n1=(MemberName *)item1;
MemberName *n2=(MemberName *)item2;
return stricmp(n1->memberName(),n2->memberName());
}
......@@ -40,6 +40,7 @@ class MemberNameIterator : public QListIterator<MemberDef>
MemberNameIterator( const MemberName &list);
};
#if 0
class MemberNameList : public QList<MemberName>
{
public:
......@@ -56,6 +57,16 @@ class MemberNameListIterator : public QListIterator<MemberName>
};
typedef QDict<MemberName> MemberNameDict;
#endif
class MemberNameSDict : public SDict<MemberName>
{
public:
MemberNameSDict(int size) : SDict<MemberName>(size) {}
~MemberNameSDict() {}
int compareItems(GCI item1,GCI item2);
};
struct MemberInfo
{
......@@ -89,6 +100,7 @@ class MemberNameInfoIterator : public QListIterator<MemberInfo>
: QListIterator<MemberInfo>(mnii) {}
};
#if 0
class MemberNameInfoList : public QList<MemberNameInfo>
{
public:
......@@ -108,6 +120,15 @@ class MemberNameInfoDict : public QDict<MemberNameInfo>
~MemberNameInfoDict() {}
};
class MemberNameInfoListIterator : public QListIterator<MemberNameInfo>
{
public:
MemberNameInfoListIterator(const MemberNameInfoList &mil) :
QListIterator<MemberNameInfo>(mil) {}
};
#endif
class MemberNameInfoSDict : public SDict<MemberNameInfo>
{
public:
......@@ -121,11 +142,4 @@ class MemberNameInfoSDict : public SDict<MemberNameInfo>
}
};
class MemberNameInfoListIterator : public QListIterator<MemberNameInfo>
{
public:
MemberNameInfoListIterator(const MemberNameInfoList &mil) :
QListIterator<MemberNameInfo>(mil) {}
};
#endif
......@@ -866,12 +866,13 @@ void addDefine()
md->setFileDef(g_yyFileDef);
md->setDefinition("#define "+g_defName);
MemberName *mn=Doxygen::functionNameDict[g_defName];
MemberName *mn=Doxygen::functionNameSDict[g_defName];
if (mn==0)
{
mn = new MemberName(g_defName);
Doxygen::functionNameList.append(mn);
Doxygen::functionNameDict.insert(g_defName,mn);
//Doxygen::functionNameList.append(mn);
//Doxygen::functionNameDict.insert(g_defName,mn);
Doxygen::functionNameSDict.append(g_defName,mn);
}
mn->append(md);
if (g_yyFileDef) g_yyFileDef->insertMember(md);
......
......@@ -150,6 +150,8 @@ static bool needsSemi;
static int depthIf;
static int initializerSharpCount;
static QCString memberGroupRelates;
static QCString memberGroupInside;
//-----------------------------------------------------------------------------
......@@ -166,6 +168,8 @@ static void initParser()
roundCount = 0;
curlyCount = 0;
memberGroupId = NOGROUP;
memberGroupRelates.resize(0);
memberGroupInside.resize(0);
mtype = Method;
gstat = FALSE;
virt = Normal;
......@@ -185,6 +189,8 @@ static void initEntry()
current->virt = virt;
current->stat = gstat;
current->mGrpId = memberGroupId;
current->relates = memberGroupRelates.copy();
current->inside = memberGroupInside.copy();
if (!autoGroupStack.isEmpty())
{
current->groups->append(new Grouping(*autoGroupStack.top()));
......@@ -1320,7 +1326,13 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
startGroup();
tmpDocType=-1;
if (current_root->section & Entry::SCOPE_MASK)
{
current->inside = current_root->name+"::";
if (current->mGrpId!=NOGROUP)
{
memberGroupInside = current->inside.copy();
}
}
if (yytext[1]=='/') // C++ style comment
{
current->brief.resize(0);
......@@ -2589,14 +2601,26 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
current->doc.resize(0);
lastDocContext = YY_START;
if (current_root->section & Entry::SCOPE_MASK)
{
current->inside = current_root->name+"::";
if (current->mGrpId!=NOGROUP)
{
memberGroupInside = current->inside.copy();
}
}
BEGIN( Doc );
}
<FindMembers,FindFields,MemberSpec,FuncQual,SkipCurly,Operator,ClassVar,SkipInits,Bases>("//"{B}*)?"/**"/[^/*] {
removeSlashes=(yytext[1]=='/');
lastDocContext = YY_START;
if (current_root->section & Entry::SCOPE_MASK)
{
current->inside = current_root->name+"::";
if (current->mGrpId!=NOGROUP)
{
memberGroupInside = current->inside.copy();
}
}
if (!Config_getBool("JAVADOC_AUTOBRIEF")) // use the Qt style
{
tmpDocType=-1;
......@@ -2629,7 +2653,13 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
tmpDocType=-1;
lastDocContext = YY_START;
if (current_root->section & Entry::SCOPE_MASK)
{
current->inside = current_root->name+"::";
if (current->mGrpId!=NOGROUP)
{
memberGroupInside = current->inside.copy();
}
}
BEGIN( LineDoc );
}
<FindMembers,FindFields,MemberSpec,FuncQual,Operator,ClassVar,Bases>"///"/[^/] {
......@@ -2637,7 +2667,13 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
tmpDocType=-1;
lastDocContext = YY_START;
if (current_root->section & Entry::SCOPE_MASK)
{
current->inside = current_root->name+"::";
if (current->mGrpId!=NOGROUP)
{
memberGroupInside = current->inside.copy();
}
}
BEGIN( LineDoc );
}
<FindMembers>"extern"{BN}+"\"C"("++")?"\""{BN}*("{")? {
......@@ -2997,6 +3033,10 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
}
<ClassDocRelates>({ID}"::")*{ID} {
current->relates = yytext;
if (current->mGrpId!=NOGROUP)
{
memberGroupRelates = yytext;
}
BEGIN( lastDocRelContext );
}
<NameSpaceDocArg1>{SCOPENAME} {
......@@ -3332,6 +3372,8 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
else if (current->section == Entry::MEMBERGRP_SEC)
{
memberGroupId = newMemberGroupId();
memberGroupRelates = current->relates.copy();
memberGroupInside = current->inside.copy();
current->mGrpId = memberGroupId;
lastMemberGroupLine = yyLineNr;
}
......@@ -3943,6 +3985,8 @@ static void startGroup()
memberGroupHeader="[NOHEADER]";
}
memberGroupId = newMemberGroupId();
memberGroupRelates = current->relates.copy();
memberGroupInside = current->inside.copy();
current->mGrpId = memberGroupId;
lastMemberGroupLine = yyLineNr;
}
......@@ -3964,9 +4008,12 @@ static void endGroup()
new QCString(memberGroupDocs)
);
memberGroupId=NOGROUP;
memberGroupRelates.resize(0);
memberGroupInside.resize(0);
if (YY_START!=ReadInitializer)
{
current->mGrpId=NOGROUP;
current->relates.resize(0);
}
memberGroupHeader.resize(0);
memberGroupDocs.resize(0);
......@@ -4056,6 +4103,8 @@ static void parseCompounds(Entry *rt)
//printf("name=%s current->stat=%d gstat=%d\n",ce->name.data(),current->stat,gstat);
memberGroupId = NOGROUP;
memberGroupRelates.resize(0);
memberGroupInside.resize(0);
scanYYlex() ;
delete current; current=0;
......
......@@ -130,6 +130,12 @@ class SDict
}
#endif
}
/*! Remove an item from the dictionary */
bool remove(const char *key)
{
T *item = m_dict->take(key);
return item ? m_list->remove(item) : FALSE;
}
/*! Sorts the members of the dictionary. First appending a number
* of members and then sorting them is faster (O(NlogN) than using
* inSort() for each member (O(N^2)).
......@@ -170,7 +176,7 @@ class SDict
}
/*! Equavalent to find(). */
T *operator[](const char *key)
T *operator[](const char *key) const
{
return m_dict->find(key);
}
......
......@@ -370,14 +370,14 @@ QCString resolveTypeDef(Definition *d,const QCString &name)
MemberDef *md=0;
while (mContext && md==0)
{
MemberNameDict *mnd=0;
MemberNameSDict *mnd=0;
if (mContext->definitionType()==Definition::TypeClass)
{
mnd=&Doxygen::memberNameDict;
mnd=&Doxygen::memberNameSDict;
}
else
{
mnd=&Doxygen::functionNameDict;
mnd=&Doxygen::functionNameSDict;
}
MemberName *mn=mnd->find(name);
if (mn)
......@@ -1080,7 +1080,7 @@ static QCString trimTemplateSpecifiers(
QCString result=s;
int i=className.length()-1;
if (className.at(i)=='>') // template specialization
if (i>=0 && className.at(i)=='>') // template specialization
{
// replace unspecialized occurrences in s, with their specialized versions.
int count=1;
......@@ -2046,7 +2046,7 @@ bool getDefs(const QCString &scName,const QCString &memberName,
//printf("mScope=`%s' mName=`%s'\n",mScope.data(),mName.data());
MemberName *mn = Doxygen::memberNameDict[mName];
MemberName *mn = Doxygen::memberNameSDict[mName];
if (!forceEmptyScope && mn && !(scopeName.isEmpty() && mScope.isEmpty()))
{
//printf(" >member name found\n");
......@@ -2157,7 +2157,7 @@ bool getDefs(const QCString &scName,const QCString &memberName,
// maybe an namespace, file or group member ?
//printf("Testing for global function scopeName=`%s' mScope=`%s' :: mName=`%s'\n",
// scopeName.data(),mScope.data(),mName.data());
if ((mn=Doxygen::functionNameDict[mName])) // name is known
if ((mn=Doxygen::functionNameSDict[mName])) // name is known
{
//printf(" >function name found\n");
NamespaceDef *fnd=0;
......@@ -2239,8 +2239,8 @@ bool getDefs(const QCString &scName,const QCString &memberName,
gd=md->getGroupDef();
//printf("md->name()=`%s' md->args=`%s' fd=%p gd=%p\n",
// md->name().data(),args,fd,gd);
if ((fd && fd->isLinkable()) ||
(gd && gd->isLinkable())
if (
(gd && gd->isLinkable()) || (fd && fd->isLinkable())
)
{
//printf("fd=%p gd=%p inGroup=`%d' args=`%s'\n",fd,gd,inGroup,args);
......@@ -2274,8 +2274,8 @@ bool getDefs(const QCString &scName,const QCString &memberName,
//printf("member is linkable md->name()=`%s'\n",md->name().data());
fd=md->getFileDef();
gd=md->getGroupDef();
if ((fd && fd->isLinkable()) ||
(gd && gd->isLinkable())
if (
(gd && gd->isLinkable()) || (fd && fd->isLinkable())
)
{
members.append(md);
......@@ -2309,6 +2309,7 @@ bool getDefs(const QCString &scName,const QCString &memberName,
{
fd=md->getFileDef();
gd=md->getGroupDef();
//printf("fd=%p gd=%p gd->isLinkable()=%d\n",fd,gd,gd->isLinkable());
if (gd && gd->isLinkable()) fd=0; else gd=0;
return TRUE;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment