From ee9ea4f80f7dac8e2e8b4c8c9ed9061e3e6abf02 Mon Sep 17 00:00:00 2001 From: Jacob Gissinger Date: Mon, 6 Dec 2021 23:08:30 -0500 Subject: [PATCH] whitespace --- doc/src/read_data.rst | 4 ++-- src/label_map.cpp | 12 ++++++------ src/read_data.cpp | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/doc/src/read_data.rst b/doc/src/read_data.rst index d98995ad3f..4e970b32c9 100644 --- a/doc/src/read_data.rst +++ b/doc/src/read_data.rst @@ -601,7 +601,7 @@ example: The 3 atoms are ordered linearly within the angle. Thus the central atom (around which the angle is computed) is the atom2 in the list. E.g. H,O,H for a water molecule. The *Angles* section must appear -after the *Atoms* section. +after the *Atoms* section. All values in this section must be integers (1, not 1.0). However, the type can be a numeric value or an alphanumeric label. The latter @@ -1130,7 +1130,7 @@ labels can be used. 12 4 17 29 30 21 The 4 atoms are ordered linearly within the dihedral. The *Dihedrals* -section must appear after the *Atoms* section. +section must appear after the *Atoms* section. All values in this section must be integers (1, not 1.0). However, the type can be a numeric value or an alphanumeric label. The latter diff --git a/src/label_map.cpp b/src/label_map.cpp index 149007d3bb..0d2e93320c 100644 --- a/src/label_map.cpp +++ b/src/label_map.cpp @@ -126,23 +126,23 @@ void LabelMap::merge_lmap(LabelMap *lmap2, int mode) switch (mode) { case Atom::ATOM: - for (auto &it : lmap2->typelabel) + for (auto &it : lmap2->typelabel) find_or_create(it,typelabel,typelabel_map); break; case Atom::BOND: - for (auto &it : lmap2->btypelabel) + for (auto &it : lmap2->btypelabel) find_or_create(it,btypelabel,btypelabel_map); break; case Atom::ANGLE: - for (auto &it : lmap2->atypelabel) + for (auto &it : lmap2->atypelabel) find_or_create(it,atypelabel,atypelabel_map); break; case Atom::DIHEDRAL: - for (auto &it : lmap2->dtypelabel) + for (auto &it : lmap2->dtypelabel) find_or_create(it,dtypelabel,dtypelabel_map); break; case Atom::IMPROPER: - for (auto &it : lmap2->itypelabel) + for (auto &it : lmap2->itypelabel) find_or_create(it,itypelabel,itypelabel_map); break; } @@ -269,7 +269,7 @@ int LabelMap::is_complete(int mode) return static_cast(typelabel_map.size()) == natomtypes; break; case Atom::BOND: - if (force->bond) + if (force->bond) return static_cast(btypelabel_map.size()) == nbondtypes; break; case Atom::ANGLE: diff --git a/src/read_data.cpp b/src/read_data.cpp index 3549161047..2dfb42c023 100644 --- a/src/read_data.cpp +++ b/src/read_data.cpp @@ -2105,7 +2105,7 @@ void ReadData::typelabels(int mode) char *buf = new char[lntypes*MAXLINE]; int eof = utils::read_lines_from_file(fp,lntypes,MAXLINE,buf,me,world); if (eof) error->all(FLERR,"Unexpected end of data file"); - + char *next; char *original = buf; char *typelabel = new char[MAXLINE]; @@ -2114,7 +2114,7 @@ void ReadData::typelabels(int mode) *next = '\0'; int rv = sscanf(buf,"%*d %s",typelabel); if (rv != 1) error->all(FLERR,"Invalid data file section: Type Labels"); - if (isdigit(typelabel[0])) + if (isdigit(typelabel[0])) error->all(FLERR,"Type labels cannot start with a number"); (*labels)[i] = typelabel; (*labels_map)[typelabel] = i + 1;