more use of utils::logmesg() and {fmt}

This commit is contained in:
Axel Kohlmeyer
2020-06-26 07:23:22 -04:00
parent 24c3f1f752
commit c4855d95e7
4 changed files with 32 additions and 65 deletions

View File

@ -21,6 +21,8 @@
#include "force.h"
#include "memory.h"
#include "error.h"
#include "utils.h"
#include "fmt/format.h"
using namespace LAMMPS_NS;
@ -301,14 +303,9 @@ Lattice::Lattice(LAMMPS *lmp, int narg, char **arg) : Pointers(lmp)
// print lattice spacings
if (comm->me == 0) {
if (screen)
fprintf(screen,"Lattice spacing in x,y,z = %g %g %g\n",
xlattice,ylattice,zlattice);
if (logfile)
fprintf(logfile,"Lattice spacing in x,y,z = %g %g %g\n",
xlattice,ylattice,zlattice);
}
if (comm->me == 0)
utils::logmesg(lmp,fmt::format("Lattice spacing in x,y,z = {} {} {}\n",
xlattice,ylattice,zlattice));
}
/* ---------------------------------------------------------------------- */