<commit_before># http://docs.python.org/library/operator.html
class Int extends Num
  __and__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value & operand.value)
    else
      super operand
  
  __add__: (operand) ->
    if issubinstance(operand, @)
       new Int(@value + operand.value)
    else
      super operand

  __div__: (operand) ->
    if issubinstance(operand, @)
      new Int(@__floordiv__(operand))
    else
      super operand

  __invert__: ->  
    new Int(~@value)
  
  __lshift__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value << operand.value)
    else
      super operand
  
  __mod__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value % operand.value)
    else
      super operand
    
  __mul__: (operand) ->
    # String * Integer and Integer * String are interchangeable in Python and
    # represent a form of string concatenation
    if Sequence in operand.__class__().__bases__()
      operand.__mul__(@)
    # **To-do** Add another branch for lists.
    else if issubinstance(operand, @)
      new Int(@value * operand.value)
    else
      super operand
    
  __or__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value | operand.value)
    else
      super operand
  
  __rshift__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value >> operand.value)
    else
      super operand
    
  __xor__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value ^ operand.value)
    else
      super operand<commit_msg>removed builtin.integer.__add__ as it's already defined in builtin.number<commit_after># http://docs.python.org/library/operator.html
class Int extends Num
  __and__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value & operand.value)
    else
      super operand
  
  __div__: (operand) ->
    if issubinstance(operand, @)
      new Int(@__floordiv__(operand))
    else
      super operand
    
  __invert__: ->  
    new Int(~@value)
  
  __lshift__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value << operand.value)
    else
      super operand
  
  __mod__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value % operand.value)
    else
      super operand
    
  __mul__: (operand) ->
    # String * Integer and Integer * String are interchangeable in Python and
    # represent a form of string concatenation
    if Sequence in operand.__class__().__bases__()
      operand.__mul__(@)
    # **To-do** Add another branch for lists.
    else if issubinstance(operand, @)
      new Int(@value * operand.value)
    else
      super operand
    
  __or__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value | operand.value)
    else
      super operand
  
  __rshift__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value >> operand.value)
    else
      super operand
    
  __xor__: (operand) ->
    if issubinstance(operand, @)
      new Int(@value ^ operand.value)
    else
      super operand
{'fraction_non_alphanumeric': 0.10801855533465872, 'fraction_numerical': 0.0, 'mean_word_length': 2.4861431870669746, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 26, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3071419', 'n_tokens_mistral': 984, 'n_tokens_neox': 1007, 'n_words': 248}