Sha256: 00a6733d93d25be03b3c055185973349aff752fc950b770f4e62d488956b98e8
Contents?: true
Size: 777 Bytes
Versions: 27
Compression:
Stored size: 777 Bytes
Contents
# frozen_string_literal: true class Code class Parser class RightOperation < Language def statement raise NotImplementedError end def whitespace Whitespace end def whitespace? whitespace.maybe end def operator raise NotImplementedError end def root ( statement.aka(:left) << ( whitespace? << operator.aka(:operator) << whitespace? << self.class.aka(:right) ).maybe ) .aka(:right_operation) .then do |output| if output[:right_operation][:right] output else output[:right_operation][:left] end end end end end end
Version data entries
27 entries across 27 versions & 1 rubygems