Converts the comments in a file.
1871{
1875 commentcnvYYlex_init_extra(&extra,&yyscanner);
1876#ifdef FLEX_DEBUG
1878#endif
1879 struct yyguts_t *yyg = (struct yyguts_t*)yyscanner;
1880
1881 yyextra->inBufPos = 0;
1882 yyextra->col = 0;
1884 yyextra->skip =
FALSE;
1885 yyextra->fileName = fileName;
1887 yyextra->pythonDocString =
FALSE;
1888 yyextra->lineNr = 1;
1889 yyextra->raiseLevel = 0;
1890 yyextra->raiseLabel = "";
1891 yyextra->raiseIncrement = 0;
1892 yyextra->raisePrefix = "";
1893 yyextra->insertCppCommentMarker=false;
1894 yyextra->expandedAliases.clear();
1895 while (!yyextra->condStack.empty()) yyextra->condStack.pop();
1897 yyextra->vhdl =
FALSE;
1898
1900 yyextra->isFixedForm =
FALSE;
1902 {
1905 }
1906
1908 {
1909 yyextra->nestingCount=0;
1910 BEGIN(CComment);
1911 yyextra->commentStack.push(yyextra->lineNr);
1912 }
1913 else
1914 {
1915 BEGIN(Scan);
1916 }
1918 while (!yyextra->condStack.empty())
1919 {
1923 warn(yyextra->fileName,ctx.
lineNr,
"Conditional section%sdoes not have "
1924 "a corresponding \\endcond command within this file.",sectionInfo.data());
1925 yyextra->condStack.pop();
1926 }
1928 {
1929 QCString tmp(
"(probable line reference: ");
1931 while (!yyextra->commentStack.empty())
1932 {
1933 int lineNr = yyextra->commentStack.top();
1934 if (!first) tmp += ", ";
1937 yyextra->commentStack.pop();
1938 }
1939 tmp += ")";
1940 warn(yyextra->fileName,yyextra->lineNr,
"Reached end of file while still inside a (nested) comment. "
1941 "Nesting level %d %s",yyextra->nestingCount,tmp.data());
1942 }
1943 yyextra->nestingCount = 0;
1945 {
1947 "output=[\n%s]\n-----------\n",
qPrint(fileName),
qPrint(yyextra->outBuf)
1948 );
1949 }
1950 commentcnvYYlex_destroy(yyscanner);
1951}
static void print(DebugMask mask, int prio, const char *fmt,...)
static bool isFlagSet(const DebugMask mask)
This is an alternative implementation of QCString.
QCString stripWhiteSpace() const
returns a copy of this string with leading and trailing whitespace removed
QCString & setNum(short n)
const char * data() const
Returns a pointer to the contents of the string in the form of a 0-terminated C string.
#define Config_getBool(name)
#define warn(file, line, fmt,...)
const char * qPrint(const char *s)
SrcLangExt getLanguageFromFileName(const QCString &fileName, SrcLangExt defLang)
bool recognizeFixedForm(const QCString &contents, FortranFormat format)
FortranFormat convertFileNameFortranParserCode(QCString fn)