2019{
2021 Token retval = Token::make_RetVal_OK();
2023
2026 DocHtmlCell *cell=nullptr;
2027
2029
2030 if (tok.
is(TokenRetval::TK_HTMLTAG))
2031 {
2034 {
2035 }
2037 {
2039 }
2040 else
2041 {
2043 "found <{}{}> instead!",
parser()->context.token->endTag ?
"/" :
"",
parser()->context.token->name);
2045 goto endrow;
2046 }
2047 }
2048 else if (tok.
is_any_of(TokenRetval::TK_NONE,TokenRetval::TK_EOF))
2049 {
2051 " for a html description title");
2052 goto endrow;
2053 }
2054 else
2055 {
2056 warn_doc_error(
parser()->context.fileName,
parser()->tokenizer.getLineNr(),
"expected <td> or <th> tag but found {} token instead!",
2058 goto endrow;
2059 }
2060
2061
2062 do
2063 {
2070 retval=cell->
parse();
2071 isHeading = retval.
is(TokenRetval::RetVal_TableHCell);
2072
2073 if (retval.
is(TokenRetval::RetVal_EndTableCell))
2074 {
2075
2077
2079 if (tok.
is(TokenRetval::TK_HTMLTAG))
2080 {
2082 !
parser()->context.token->endTag)
2083 {
2084 retval = Token::make_RetVal_TableCell();
2086 }
2088 {
2089 if (
parser()->context.token->endTag)
2090 {
2091 retval = Token::make_RetVal_EndTableRow();
2092 }
2093 else
2094 {
2095 retval = Token::make_RetVal_TableRow();
2096 }
2097 }
2099 {
2100 retval = Token::make_RetVal_EndTable();
2101 }
2102 else
2103 {
2105 "found <{}{}> instead!",
parser()->context.token->endTag ?
"/" :
"",
parser()->context.token->name);
2107 goto endrow;
2108 }
2109 }
2110 else
2111 {
2112 warn_doc_error(
parser()->context.fileName,
parser()->tokenizer.getLineNr(),
"expected <td>, <th> or <tr> tag but found {} token instead!",
2114 goto endrow;
2115 }
2116 }
2117 }
2118 while (retval.
is_any_of(TokenRetval::RetVal_TableCell,TokenRetval::RetVal_TableHCell));
2120
2121endrow:
2122 return retval;
2123}
void markLast(bool v=TRUE)
void markFirst(bool v=TRUE)
DocNodeVariant * thisVariant()
void pushBackHtmlTag(const QCString &tag)
bool is(TokenRetval rv) const
TOKEN_SPECIFICATIONS RETVAL_SPECIFICATIONS const char * to_string() const
bool is_any_of(ARGS... args) const
static Token skipSpacesForTable(DocParser *parser)
#define warn_doc_error(file, line, fmt,...)
const Mapper< HtmlTagType > * htmlTagMapper
void append(Args &&... args)
Append a new DocNodeVariant to the list by constructing it with type T and parameters Args.
T * get_last()
Returns a pointer to the last element in the list if that element exists and holds a T,...