Reindented the sorting of occurrences over several lines as suggested by rubocop
Replaced perl-style global regexp variables with Regexp.last_match as
suggested by rubocop
Replaced begin...end while loop with loop do... break if... as suggested
by rubocop
Reindented occurrence as suggested by rubocop
Refactored RecurrenceConstruct#interpret and
RecurrenceConstruct#variant_of? into the same method

Should be more efficient and reduces the amount of code