Add enumeration out of range and trim checks and updated results