Changing RuntimeExceptions to ProgramErrorExceptions.