Added more docs and tests to EnumerationArray
commit17e6e26c3f16ce5c5a5ff3c8b7d01fdc8aa7db7c
authorMark Abraham <mark.j.abraham@gmail.com>
Mon, 17 Feb 2020 07:22:38 +0000 (17 08:22 +0100)
committerChristian Blau <cblau@gerrit.gromacs.org>
Tue, 18 Feb 2020 10:52:11 +0000 (18 11:52 +0100)
treed9353393011c12460f7790fd739f1ac1c882d427
parent6dc7d1eca386ea29c50500c975a62ad44c9139fd
Added more docs and tests to EnumerationArray

It is now more clear that there is no risk of a segfault if somehow
Foo::Count was used to look up a value from an EnumerationArray. The
assertion would not be nice for a user to get either, but the positive
aspects that flow from having enumeration helpers that need the Count
field outweighs this downside.

Change-Id: I6111e79042326044a807b9b8ac58f32760a56b82
src/gromacs/utility/enumerationhelpers.h
src/gromacs/utility/tests/enumerationhelpers.cpp