fix implementation of consistency check C5
fixes #70