Skip to content

Commit

Permalink
Warnings from CLANG compiler
Browse files Browse the repository at this point in the history
The CLANG compiler gave some warnings after pull request #503 ("Introducing commands includedoc and snippetdoc ") at places that are not / should not be reachable.
  • Loading branch information
albert-github committed Aug 28, 2016
1 parent 725c7e3 commit fdfb027
Show file tree
Hide file tree
Showing 9 changed files with 46 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/docbookvisitor.cpp
Expand Up @@ -359,6 +359,11 @@ void DocbookDocVisitor::visit(DocInclude *inc)
);
m_t << "</computeroutput></literallayout>";
break;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
}

Expand Down
5 changes: 5 additions & 0 deletions src/docparser.cpp
Expand Up @@ -1941,6 +1941,11 @@ void DocInclude::parse()
m_blockId.data(),m_file.data(),count);
}
break;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
}

Expand Down
5 changes: 5 additions & 0 deletions src/htmldocvisitor.cpp
Expand Up @@ -585,6 +585,11 @@ void HtmlDocVisitor::visit(DocInclude *inc)
forceStartParagraph(inc);
}
break;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
}

Expand Down
5 changes: 5 additions & 0 deletions src/latexdocvisitor.cpp
Expand Up @@ -483,6 +483,11 @@ void LatexDocVisitor::visit(DocInclude *inc)
m_t << "\\end{DoxyCodeInclude}" << endl;
}
break;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
}

Expand Down
5 changes: 5 additions & 0 deletions src/mandocvisitor.cpp
Expand Up @@ -306,6 +306,11 @@ void ManDocVisitor::visit(DocInclude *inc)
m_t << ".PP" << endl;
m_firstCol=TRUE;
break;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
}

Expand Down
5 changes: 5 additions & 0 deletions src/perlmodgen.cpp
Expand Up @@ -716,6 +716,11 @@ void PerlModDocVisitor::visit(DocInclude *inc)
case DocInclude::LatexInclude: type = "latexonly"; break;
case DocInclude::VerbInclude: type = "preformatted"; break;
case DocInclude::Snippet: return;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
openItem(type);
m_output.addFieldQuotedString("content", inc->text());
Expand Down
6 changes: 6 additions & 0 deletions src/printdocvisitor.h
Expand Up @@ -22,6 +22,7 @@
#include <qglobal.h>
#include "docvisitor.h"
#include "htmlentity.h"
#include "message.h"

/*! Concrete visitor implementation for pretty printing */
class PrintDocVisitor : public DocVisitor
Expand Down Expand Up @@ -170,6 +171,11 @@ class PrintDocVisitor : public DocVisitor
case DocInclude::LatexInclude: printf("latexinclude"); break;
case DocInclude::VerbInclude: printf("verbinclude"); break;
case DocInclude::Snippet: printf("snippet"); break;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
printf("\"/>");
}
Expand Down
5 changes: 5 additions & 0 deletions src/rtfdocvisitor.cpp
Expand Up @@ -444,6 +444,11 @@ void RTFDocVisitor::visit(DocInclude *inc)
);
m_t << "}";
break;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
m_lastIsPara=TRUE;
}
Expand Down
5 changes: 5 additions & 0 deletions src/xmldocvisitor.cpp
Expand Up @@ -329,6 +329,11 @@ void XmlDocVisitor::visit(DocInclude *inc)
);
m_t << "</programlisting>";
break;
case DocInclude::SnippetDoc:
case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
}
}

Expand Down

0 comments on commit fdfb027

Please sign in to comment.