struct Backtracer::Backtrace::Frame::Context

Defined in:

backtracer/backtrace/frame/context.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(lineno : Int32, pre : Array(String), line : String, post : Array(String)) #

[View source]

Instance Method Detail

def line : String #

The line at #lineno.


[View source]
def lineno : Int32 #

The line number this Context refers to.


[View source]
def post : Array(String) #

An array of lines after #lineno.


[View source]
def pre : Array(String) #

An array of lines before #lineno.


[View source]
def to_a : Array(String) #

Returns an array composed of context lines from #pre, #line and #post.


[View source]
def to_h : Hash(Int32, String) #

Returns hash with context lines, where line numbers are the keys and the lines itself are the values.


[View source]