Print warning about unsorted custom dumps without atom IDs. Explain in manual.

This commit is contained in:
Axel Kohlmeyer
2023-01-04 08:42:43 -05:00
parent 56cb967991
commit 3e053adfbe
4 changed files with 21 additions and 2 deletions

View File

@ -1245,11 +1245,14 @@ int DumpCustom::parse_fields(int narg, char **arg)
{
// customize by adding to if statement
has_id = 0;
for (int iarg = 0; iarg < narg; iarg++) {
if (strcmp(arg[iarg],"id") == 0) {
pack_choice[iarg] = &DumpCustom::pack_id;
if (sizeof(tagint) == sizeof(smallint)) vtype[iarg] = Dump::INT;
else vtype[iarg] = Dump::BIGINT;
has_id = 1;
} else if (strcmp(arg[iarg],"mol") == 0) {
if (!atom->molecule_flag)
error->all(FLERR,"Dumping an atom property that isn't allocated");