diff options
-rw-r--r-- | src/docvisitor.cpp | 12 | ||||
-rw-r--r-- | src/docvisitor.h | 2 | ||||
-rw-r--r-- | src/doxygen.cpp | 18 |
3 files changed, 19 insertions, 13 deletions
diff --git a/src/docvisitor.cpp b/src/docvisitor.cpp index 664d3ca..17aefc2 100644 --- a/src/docvisitor.cpp +++ b/src/docvisitor.cpp @@ -27,9 +27,9 @@ struct DocVisitor::Private std::unordered_map< std::string, std::unique_ptr<CodeParserInterface> > parserFactoryMap; }; -DocVisitor::DocVisitor(int id) : p(std::make_unique<Private>()) +DocVisitor::DocVisitor(int id) : m_p(std::make_unique<Private>()) { - p->id = id; + m_p->id = id; } DocVisitor::~DocVisitor() @@ -42,11 +42,11 @@ CodeParserInterface &DocVisitor::getCodeParser(const char *extension) // for each extension we create a code parser once per visitor, so that // the context of the same parser object is reused thoughout multiple passes for instance // for code fragments shown via dontinclude. - auto it = p->parserFactoryMap.find(ext); - if (it==p->parserFactoryMap.end()) + auto it = m_p->parserFactoryMap.find(ext); + if (it==m_p->parserFactoryMap.end()) { auto factory = Doxygen::parserManager->getCodeParserFactory(extension); - auto result = p->parserFactoryMap.insert(std::make_pair(ext,factory())); + auto result = m_p->parserFactoryMap.insert(std::make_pair(ext,factory())); it = result.first; } return *it->second.get(); @@ -54,5 +54,5 @@ CodeParserInterface &DocVisitor::getCodeParser(const char *extension) int DocVisitor::id() const { - return p->id; + return m_p->id; } diff --git a/src/docvisitor.h b/src/docvisitor.h index 105b97c..4d4b263 100644 --- a/src/docvisitor.h +++ b/src/docvisitor.h @@ -90,7 +90,7 @@ class CodeParserInterface; class DocVisitor { struct Private; - std::unique_ptr<Private> p; + std::unique_ptr<Private> m_p; public: DocVisitor(int id); virtual ~DocVisitor(); diff --git a/src/doxygen.cpp b/src/doxygen.cpp index a416c7b..d442857 100644 --- a/src/doxygen.cpp +++ b/src/doxygen.cpp @@ -7514,8 +7514,9 @@ static void generateFileSources() { msg("Generating code for file %s...\n",fd->docName().data()); clangParser->parse(); - fd->writeSource(*g_outputList,clangParser.get()); - + fd->writeSourceHeader(*g_outputList); + fd->writeSourceBody(*g_outputList,clangParser.get()); + fd->writeSourceFooter(*g_outputList); } else if (!fd->isReference() && Doxygen::parseSourcesNeeded) // we needed to parse the sources even if we do not show them @@ -7539,7 +7540,9 @@ static void generateFileSources() if (ifd->generateSourceFile() && !g_useOutputTemplate) // sources need to be shown in the output { msg(" Generating code for file %s...\n",ifd->docName().data()); - ifd->writeSource(*g_outputList,clangParser.get()); + ifd->writeSourceHeader(*g_outputList); + ifd->writeSourceBody(*g_outputList,clangParser.get()); + ifd->writeSourceFooter(*g_outputList); } else if (!ifd->isReference() && Doxygen::parseSourcesNeeded) // we needed to parse the sources even if we do not show them @@ -7567,15 +7570,18 @@ static void generateFileSources() { msg("Generating code for file %s...\n",fd->docName().data()); clangParser->parse(); - fd->writeSource(*g_outputList,clangParser.get()); - + fd->writeSourceHeader(*g_outputList); + fd->writeSourceBody(*g_outputList,clangParser.get()); + fd->writeSourceFooter(*g_outputList); } else if (!fd->isReference() && Doxygen::parseSourcesNeeded) // we needed to parse the sources even if we do not show them { msg("Parsing code for file %s...\n",fd->docName().data()); clangParser->parse(); - fd->parseSource(clangParser.get()); + fd->writeSourceHeader(*g_outputList); + fd->writeSourceBody(*g_outputList,clangParser.get()); + fd->writeSourceFooter(*g_outputList); } } } |