simplify code by appling varargs messages and warnings

This commit is contained in:
Axel Kohlmeyer
2021-05-05 18:19:12 -04:00
parent 8fd0595f1b
commit 22e93468d6
48 changed files with 162 additions and 181 deletions

View File

@ -458,25 +458,23 @@ void PairTable::read_table(Table *tb, char *file, char *keyword)
}
if (ferror)
error->warning(FLERR,fmt::format("{} of {} force values in table {} are "
"inconsistent with -dE/dr.\n Should "
"only be flagged at inflection points",
ferror,tb->ninput,keyword));
error->warning(FLERR,"{} of {} force values in table {} are inconsistent "
"with -dE/dr.\nWARNING: Should only be flagged at "
"inflection points",ferror,tb->ninput,keyword);
// warn if re-computed distance values differ from file values
if (rerror)
error->warning(FLERR,fmt::format("{} of {} distance values in table {} "
"with relative error\n over {} to "
"re-computed values",
rerror,tb->ninput,EPSILONR,keyword));
error->warning(FLERR,"{} of {} distance values in table {} with relative "
"error\nWARNING: over {} to re-computed values",
rerror,tb->ninput,EPSILONR,keyword);
// warn if data was read incompletely, e.g. columns were missing
if (cerror)
error->warning(FLERR,fmt::format("{} of {} lines in table {} were "
"incomplete\n or could not be parsed "
"completely",cerror,tb->ninput,keyword));
error->warning(FLERR,"{} of {} lines in table {} were incomplete\n"
"WARNING: or could not be parsed completely",
cerror,tb->ninput,keyword);
}
/* ----------------------------------------------------------------------