peptide dihedral angle definitions violate IUPAC
(and related code probably does who knows what other nasty stuff!)
Standard IUPAC definititions of phi/psi/omega angles (http://www.chem.qmul.ac.uk/iupac/misc/ppep3.html#320) are only vaguely followed by the code for g_chi. Perhaps other code like g_rama or g_angle has related problems.
These definitions should follow IUPAC and probably be implemented via selections in 5.0. At the very least, the lookups via atom names should be consolidated in one place. Numerous bugs have already been revealed by the CHARMM convention of naming hydrogen bonded to nitrogen as "NH", which was not anticipated by the original developers of various GROMACS tools, who hard-coded other strings in multiple places.