Sha256: 6e6c069762b0c977fddeea3cdcb17f1563c02b809754b6c5966c27a5d86cf27d
Contents?: true
Size: 421 Bytes
Versions: 13
Compression:
Stored size: 421 Bytes
Contents
module CrashLog class Backtrace class LineCache class << self CACHE = {} def getlines(path) CACHE[path] ||= begin IO.readlines(path).map { |line| line.chomp.gsub(/[']/, '\\\\\'') } rescue [] end end def getline(path, n) return nil if n < 1 getlines(path)[n-1] end end end end end
Version data entries
13 entries across 13 versions & 1 rubygems