diff options
Diffstat (limited to 'src/commentscan.l')
-rw-r--r-- | src/commentscan.l | 35 |
1 files changed, 16 insertions, 19 deletions
diff --git a/src/commentscan.l b/src/commentscan.l index edd4910..6e7d373 100644 --- a/src/commentscan.l +++ b/src/commentscan.l @@ -533,7 +533,7 @@ static void addXRefItem(const char *listName,const char *itemTitle, if (listName==0) return; //printf("addXRefItem(%s,%s,%s,%d)\n",listName,itemTitle,listTitle,append); - ListItemInfo *lii=0; + const ListItemInfo *lii=0; RefList *refList = Doxygen::xrefLists->find(listName); if (refList==0) // new list { @@ -541,16 +541,13 @@ static void addXRefItem(const char *listName,const char *itemTitle, Doxygen::xrefLists->insert(listName,refList); //printf("new list!\n"); } - if (current->sli) + for (const ListItemInfo &item : current->sli) { - QListIterator<ListItemInfo> slii(*current->sli); - for (slii.toLast();(lii=slii.current());--slii) + if (qstrcmp(item.type,listName)==0) { - if (qstrcmp(lii->type,listName)==0) - { - //printf("found %s lii->type=%s\n",listName,lii->type); - break; - } + //printf("found %s lii->type=%s\n",listName,lii->type); + lii = &item; + break; } } if (lii && append) // already found item of same type just before this one @@ -605,7 +602,7 @@ static void addXRefItem(const char *listName,const char *itemTitle, g_sectionTitle,SectionInfo::Anchor, g_sectionLevel); Doxygen::sectionDict->append(anchorLabel,si); - current->anchors->append(si); + current->anchors.push_back(si); } } outputXRef.resize(0); @@ -673,7 +670,7 @@ static void addSection() g_sectionTitle,sectionLevelToType(g_sectionLevel),g_sectionLevel); // add section to this entry - current->anchors->append(si); + current->anchors.push_back(si); // add section to the global dictionary Doxygen::sectionDict->append(g_sectionLabel,si); @@ -850,7 +847,7 @@ static void addAnchor(const char *anchor) { si = new SectionInfo(yyFileName,yyLineNr,anchor,0,SectionInfo::Anchor,0); Doxygen::sectionDict->append(anchor,si); - current->anchors->append(si); + current->anchors.push_back(si); } } @@ -1824,7 +1821,7 @@ RCSTAG "$"{ID}":"[^\n$]+"$" addOutput(yytext); // we add subpage labels as a kind of "inheritance" relation to prevent // needing to add another list to the Entry class. - current->extends->append(new BaseInfo(yytext,Public,Normal)); + current->extends.push_back(BaseInfo(yytext,Public,Normal)); BEGIN(SubpageTitle); } <SubpageLabel>{DOCNL} { // missing argument @@ -2141,8 +2138,8 @@ RCSTAG "$"{ID}":"[^\n$]+"$" /* ----- handle argument of ingroup command ------- */ <InGroupParam>{LABELID} { // group id - current->groups->append( - new Grouping(yytext, Grouping::GROUPING_INGROUP) + current->groups.push_back( + Grouping(yytext, Grouping::GROUPING_INGROUP) ); inGroupParamFound=TRUE; } @@ -2224,8 +2221,8 @@ RCSTAG "$"{ID}":"[^\n$]+"$" /* ----- handle argument of inherit command ------- */ <InheritParam>({ID}("::"|"."))*{ID} { // found argument - current->extends->append( - new BaseInfo(removeRedundantWhiteSpace(yytext),Public,Normal) + current->extends.push_back( + BaseInfo(removeRedundantWhiteSpace(yytext),Public,Normal) ); BEGIN( Comment ); } @@ -2247,8 +2244,8 @@ RCSTAG "$"{ID}":"[^\n$]+"$" /* ----- handle argument of extends and implements commands ------- */ <ExtendsParam>({ID}("::"|"."))*{ID} { // found argument - current->extends->append( - new BaseInfo(removeRedundantWhiteSpace(yytext),Public,Normal) + current->extends.push_back( + BaseInfo(removeRedundantWhiteSpace(yytext),Public,Normal) ); BEGIN( Comment ); } |