Module: Byebug::DisplayFunctions
- Defined in:
- lib/byebug/commands/display.rb
Instance Method Summary collapse
- #active_display_expressions? ⇒ Boolean
- #display_expression(exp) ⇒ Object
- #print_display_expressions ⇒ Object
Instance Method Details
#active_display_expressions? ⇒ Boolean
7 8 9 |
# File 'lib/byebug/commands/display.rb', line 7 def active_display_expressions? @state.display.select{|d| d[0]}.size > 0 end |
#display_expression(exp) ⇒ Object
3 4 5 |
# File 'lib/byebug/commands/display.rb', line 3 def display_expression(exp) print "#{exp} = #{bb_warning_eval(exp).inspect}\n" end |
#print_display_expressions ⇒ Object
11 12 13 14 15 16 17 18 19 20 |
# File 'lib/byebug/commands/display.rb', line 11 def print_display_expressions n = 1 for d in @state.display if d[0] print "#{n}: " display_expression(d[1]) end n += 1 end end |