<commit_before>module Fauxsql
  # AttributeList is an Array that dereferences and resolves fauxsql attributes
  # when setting/reading members in the Array
  class AttributeList < Array
    include Attribute
    
    def <<(attribute)
      super Fauxsql.dereference_fauxsql_attribute(attribute)
    end
    
    def [] index
      Fauxsql.resolve_fauxsql_attribute super(index)
    end
    
    def first
      self[0]
    end
    
    def last
      self[length - 1]
    end
    
    def each
      map_resolved.each { |resolved| yield resolved }
    end
    
    def equals list
      map_resolved == list
    end
    
    def map_resolved
      map = []
      each_with_index do |item, index| 
        map[index] = self[index]
      end
      map
    end    
  end
end<commit_msg>each gives unresolved dereferences<commit_after>module Fauxsql
  # AttributeList is an Array that dereferences and resolves fauxsql attributes
  # when setting/reading members in the Array
  class AttributeList < Array
    include Attribute
    
    def <<(attribute)
      super Fauxsql.dereference_fauxsql_attribute(attribute)
    end
    
    def [] index
      Fauxsql.resolve_fauxsql_attribute super(index)
    end
    
    def first
      self[0]
    end
    
    def last
      self[length - 1]
    end
        
    def equals list
      map_resolved == list
    end
    
    def map_resolved
      map = []
      each_with_index do |item, index| 
        map[index] = self[index]
      end
      map
    end    
  end
end
{'fraction_non_alphanumeric': 0.05221414408460013, 'fraction_numerical': 0.0026437541308658294, 'mean_word_length': 2.0340681362725452, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 3, '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': '3490831', 'n_tokens_mistral': 457, 'n_tokens_neox': 447, 'n_words': 133}