In Files
- irb/frame.rb
Class/Module Index
- IRB::Abort
- IRB::Context
- IRB::ContextExtender
- IRB::ExtendCommandBundle
- IRB::FileInputMethod
- IRB::Frame
- IRB::InputMethod
- IRB::Inspector
- IRB::Irb
- IRB::IrbLoader
- IRB::JobManager
- IRB::LoadAbort
- IRB::MethodExtender
- IRB::Notifier
- IRB::Notifier::AbstractNotifier
- IRB::Notifier::CompositeNotifier
- IRB::Notifier::LeveledNotifier
- IRB::Notifier::NoMsgNotifier
- IRB::OutputMethod
- IRB::ReadlineInputMethod
- IRB::StdioInputMethod
- IRB::StdioOutputMethod
- IRB::WorkSpace
- Object
- XMP
- XMP::StringInputMethod
IRB::Frame
Constants
- CALL_STACK_OFFSET
Default number of frames offset
- INIT_STACK_TIMES
Default number of stack frames
Public Class Methods
bottom(n = 0)
Convenience method for #bottom
# File irb/frame.rb, line 62 def Frame.bottom(n = 0) @backtrace.bottom(n) end
new()
Creates a new stack frame
# File irb/frame.rb, line 27 def initialize @frames = [TOPLEVEL_BINDING] * INIT_STACK_TIMES end
sender()
Returns the binding context of the caller from the last frame initialized
# File irb/frame.rb, line 72 def Frame.sender eval "self", @backtrace.top end
top(n = 0)
Convenience method for #top
# File irb/frame.rb, line 67 def Frame.top(n = 0) @backtrace.top(n) end
Public Instance Methods
bottom(n = 0)
Returns the n
number of frames on the call stack from the
first frame initialized.
Raises FrameOverflow if there are no frames in the given stack range.
# File irb/frame.rb, line 55 def bottom(n = 0) bind = @frames[n] Fail FrameOverflow unless bind bind end