Skip to content

Commit

Permalink
Merge branch 'master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
andyjeffries authored Sep 25, 2023
2 parents c555245 + 3d822a1 commit 5ce9b5e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion debug.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,5 @@ Gem::Specification.new do |spec|
spec.extensions = ['ext/debug/extconf.rb']

spec.add_dependency "irb", ">= 1.5.0" # for binding.irb(show_code: false)
spec.add_dependency "reline", ">= 0.3.1"
spec.add_dependency "reline", ">= 0.3.8"
end
8 changes: 4 additions & 4 deletions lib/debug/console.rb
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,10 @@ def readline_setup prompt
Reline.prompt_proc = -> args, *kw do
case state = parse_input(args.first, commands)
when nil, :command
[prompt, prompt]
[prompt]
when :ruby
[prompt.sub('rdbg'){colorize('ruby', [:RED])}] * 2
end
[prompt.sub('rdbg'){colorize('ruby', [:RED])}]
end * args.size
end

Reline.completion_proc = -> given do
Expand Down Expand Up @@ -96,7 +96,7 @@ def readline_setup prompt
when nil
buff
when :ruby
colorize_code(buff.chomp)
colorize_code(buff)
end
end unless CONFIG[:no_hint]

Expand Down
4 changes: 2 additions & 2 deletions test/console/backtrace_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def program
14| end
15| end
16|
17| 3.times do
17| [1, 2, 3].each do
18| Foo.new.first_call
19| end
RUBY
Expand All @@ -33,7 +33,7 @@ def test_backtrace_prints_c_method_frame
type 'b 18'
type 'c'
type 'bt'
assert_line_text(/\[C\] Integer#times/)
assert_line_text(/\[C\] Array#each/)
type 'kill!'
end
end
Expand Down

0 comments on commit 5ce9b5e

Please sign in to comment.