From 7adb2d7bcf4a8b6958cd68d62c2918e9d576effc Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 4 Aug 2023 17:13:53 -0400 Subject: [PATCH] fix syntax issues --- doc/src/fix_vector.rst | 2 +- src/fix_vector.cpp | 3 ++- src/fix_vector.h | 8 ++++---- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/doc/src/fix_vector.rst b/doc/src/fix_vector.rst index 40da988b1d..12a2419638 100644 --- a/doc/src/fix_vector.rst +++ b/doc/src/fix_vector.rst @@ -193,6 +193,6 @@ Defaults """""""" The default value of *nmax* is deduced from the number of steps -in a run (or multiple runs when using the *start* and *stop* +in a run (or multiple runs when using the *start* and *stop* keywords of the :doc:`run command `) divided by the choice of *Nevery* plus 1. diff --git a/src/fix_vector.cpp b/src/fix_vector.cpp index fde24b716c..4983239de9 100644 --- a/src/fix_vector.cpp +++ b/src/fix_vector.cpp @@ -57,9 +57,10 @@ FixVector::FixVector(LAMMPS *lmp, int narg, char **arg) : val.id = argi.get_name(); val.val.c = nullptr; - if ((val.which == ArgInfo::UNKNOWN) || (val.which == ArgInfo::NONE) || (argi.get_dim() > 1)) + if ((val.which == ArgInfo::UNKNOWN) || (argi.get_dim() > 1)) error->all(FLERR, "Invalid fix vector argument: {}", arg[iarg]); + if (val.which == ArgInfo::NONE) break; values.push_back(val); ++iarg; } diff --git a/src/fix_vector.h b/src/fix_vector.h index 7f5394702c..275ccbb4c1 100644 --- a/src/fix_vector.h +++ b/src/fix_vector.h @@ -50,10 +50,10 @@ class FixVector : public Fix { bigint nextstep, initialstep; - int ncount; // # of values currently in growing vector or array - int ncountmax; // max # of values vector/array can hold - int nmaxval; // maximum allowed number of values - int nindex; // start index of data, may wrap around + bigint ncount; // # of values processed and stored into growing vector or array + bigint ncountmax; // max # of values vector/array can hold + bigint nmaxval; // maximum allowed number of values + bigint nindex; // start index of data, may wrap around double *vector; double **array;