Fix all -Werror=enum-int-mismatch warnings
For some reasons, likely after updating to a new gcc or , building c-tor has a lot of -Werror=enum-int-mismatch
errors. So this ticket is for fixing them all.
I'm going to backport this else I can't build properly 047 :S.