From ea512ce2bbaaed4f9d68fc28aa836af34dee2e40 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 3 Oct 2022 09:22:28 -0400 Subject: [PATCH] update comments about which files to keep synchronized for consistency --- python/lammps/constants.py | 3 ++- src/library.h | 20 ++++++++++---------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/python/lammps/constants.py b/python/lammps/constants.py index a76be819fe..6fe7750326 100644 --- a/python/lammps/constants.py +++ b/python/lammps/constants.py @@ -22,7 +22,8 @@ LAMMPS_INT64 = 4 LAMMPS_INT64_2D = 5 LAMMPS_STRING = 6 -# these must be kept in sync with the enums in library.h +# these must be kept in sync with the enums in src/library.h, tools/swig/lammps.i +# and the constants in fortran/lammps.f90 LMP_STYLE_GLOBAL = 0 LMP_STYLE_ATOM = 1 LMP_STYLE_LOCAL = 2 diff --git a/src/library.h b/src/library.h index 9adb274518..814c24210d 100644 --- a/src/library.h +++ b/src/library.h @@ -40,8 +40,8 @@ /** Data type constants for extracting data from atoms, computes and fixes * - * Must be kept in sync with the equivalent constants in lammps/constants.py - * and fortran/lammps.f90 */ + * Must be kept in sync with the equivalent constants in python/lammps/constants.py, + * fortran/lammps.f90, and tools/swig/lammps.i */ enum _LMP_DATATYPE_CONST { LAMMPS_INT = 0, /*!< 32-bit integer (array) */ @@ -55,8 +55,8 @@ enum _LMP_DATATYPE_CONST { /** Style constants for extracting data from computes and fixes. * - * Must be kept in sync with the equivalent constants in lammps/constants.py - * and fortran/lammps.f90 */ + * Must be kept in sync with the equivalent constants in python/lammps/constants.py, + * fortran/lammps.f90, and tools/swig/lammps.i */ enum _LMP_STYLE_CONST { LMP_STYLE_GLOBAL = 0, /*!< return global data */ @@ -66,8 +66,8 @@ enum _LMP_STYLE_CONST { /** Type and size constants for extracting data from computes and fixes. * - * Must be kept in sync with the equivalent constants in lammps/constants.py - * and fortran/lammps.f90 */ + * Must be kept in sync with the equivalent constants in python/lammps/constants.py, + * fortran/lammps.f90, and tools/swig/lammps.i */ enum _LMP_TYPE_CONST { LMP_TYPE_SCALAR = 0, /*!< return scalar */ @@ -80,8 +80,8 @@ enum _LMP_TYPE_CONST { /** Error codes to select the suitable function in the Error class * - * Must be kept in sync with the equivalent constants in lammps/constants.py - * and fortran/lammps.f90 */ + * Must be kept in sync with the equivalent constants in python/lammps/constants.py, + * fortran/lammps.f90, and tools/swig/lammps.i */ enum _LMP_ERROR_CONST { LMP_ERROR_WARNING = 0, /*!< call Error::warning() */ @@ -93,8 +93,8 @@ enum _LMP_ERROR_CONST { /** Variable style constants for extracting data from variables. * - * Must be kept in sync with the equivalent constants in lammps/constants.py - * and fortran/lammps.f90 */ + * Must be kept in sync with the equivalent constants in python/lammps/constants.py, + * fortran/lammps.f90, and tools/swig/lammps.i */ enum _LMP_VAR_CONST { LMP_VAR_EQUAL = 0, /*!< compatible with equal-style variables */