// You should also run the development/tools/updatelayouts.py script,
// to update the format of all of our layout files.
//
// You should also run the development/tools/updatelayouts.py script,
// to update the format of all of our layout files.
//
opt_enginetype_("authoryear|numerical"), opt_fontsize_("10|11|12"),
opt_pagestyle_("empty|plain|headings|fancy"), pagestyle_("default"),
columns_(1), sides_(OneSide), secnumdepth_(3), tocdepth_(3),
opt_enginetype_("authoryear|numerical"), opt_fontsize_("10|11|12"),
opt_pagestyle_("empty|plain|headings|fancy"), pagestyle_("default"),
columns_(1), sides_(OneSide), secnumdepth_(3), tocdepth_(3),
- outputType_(LATEX), outputFormat_("latex"),
+ outputType_(LATEX), outputFormat_("latex"), has_output_format_(false),
defaultfont_(sane_font),
titletype_(TITLE_COMMAND_AFTER), titlename_("maketitle"),
min_toclevel_(0), max_toclevel_(0), maxcitenames_(2),
defaultfont_(sane_font),
titletype_(TITLE_COMMAND_AFTER), titlename_("maketitle"),
min_toclevel_(0), max_toclevel_(0), maxcitenames_(2),
- // Format of files before the 'Format' tag was introduced
- int format = 1;
- bool error = false;
+ // The first usable line should be
+ // Format LAYOUT_FORMAT
+ if (lexrc.lex() != TC_FORMAT || !lexrc.next()
+ || lexrc.getInteger() != LAYOUT_FORMAT)
+ return FORMAT_MISMATCH;
// If the layout already exists, then we want to add it to
// the existing layout, as long as we are not in an ProvideStyle
// block.
// If the layout already exists, then we want to add it to
// the existing layout, as long as we are not in an ProvideStyle
// block.
- // false positive from coverity
- // coverity[checked_return]
- readStyle(lexrc, lay);
+ // signal to coverity that we do not care about the result
+ (void)readStyle(lexrc, lay);
if (type & ENGINE_TYPE_AUTHORYEAR)
cite_macros_[ENGINE_TYPE_AUTHORYEAR][etype] = definition;
if (type & ENGINE_TYPE_NUMERICAL)
if (type & ENGINE_TYPE_AUTHORYEAR)
cite_macros_[ENGINE_TYPE_AUTHORYEAR][etype] = definition;
if (type & ENGINE_TYPE_NUMERICAL)
for (; lit != len; ++lit) {
int const level = lit->toclevel;
// we don't want Part or unnumbered sections
for (; lit != len; ++lit) {
int const level = lit->toclevel;
// we don't want Part or unnumbered sections