irb 1.6.0 → 1.6.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2df1f78bfd3e28e4102262fc4b9011d6c84c7690cba11f870e6e9f54e8718ebe
4
- data.tar.gz: 20d55eba407c974060b73fc4ba741d534da8f933f65ec1bb03e85ba36129dc01
3
+ metadata.gz: 7a14d4867e5744e554edbcd7e87f397bd01305fd2e5dca129bfa4d0a49abdd12
4
+ data.tar.gz: b6ed771b62fc49d60ac292a87cd5bafb2ec79b5715ec73bc816923fcb68de2ea
5
5
  SHA512:
6
- metadata.gz: a829406c154fb4cb7d877ebe95bfb8ab20dd894e6adaaa4fd05ee198740f2deff0a449c469ff1c388075424b04ecd28db6bb3298c345c46b9c821ffb8f1d4ad4
7
- data.tar.gz: 0fde56ad653b34522edcc1f9d5f8d2524ced3551b1f1f3ff1b99226b8263433b27c416b10121ae6fdeb2ed82541341fe6dfd8e8e1ff712d01e3c32d69b6707b6
6
+ metadata.gz: 0acdbeae9c9aa9a83677a903ddf5006f82dc2dd4697d1e089ec360d0f77f049ebbaf3492b3ca5bda0a7c8814bac0e5ccde351e5a2d2c487170761d874204f02c
7
+ data.tar.gz: 4f92f7aadb2876a4d774ac52f27701cb8c723f400000a560f2452779b9562ad0d1a202b4534a52029662d0a2f910cdd816bdf43e275b800211c9ec062ae1241e
data/lib/irb/cmd/debug.rb CHANGED
@@ -55,6 +55,13 @@ module IRB
55
55
  end
56
56
  end
57
57
 
58
+ module SkipPathHelperForIRB
59
+ def skip_internal_path?(path)
60
+ # The latter can be removed once https://github.com/ruby/debug/issues/866 is resolved
61
+ super || path.match?(IRB_DIR) || path.match?('<internal:prelude>')
62
+ end
63
+ end
64
+
58
65
  def setup_debugger
59
66
  unless defined?(DEBUGGER__::SESSION)
60
67
  begin
@@ -75,6 +82,8 @@ module IRB
75
82
  end
76
83
  frames
77
84
  end
85
+
86
+ DEBUGGER__::ThreadClient.prepend(SkipPathHelperForIRB)
78
87
  end
79
88
 
80
89
  true
data/lib/irb/cmd/edit.rb CHANGED
@@ -18,13 +18,6 @@ module IRB
18
18
  args.strip.dump
19
19
  end
20
20
  end
21
-
22
- private
23
-
24
- def string_literal?(args)
25
- sexp = Ripper.sexp(args)
26
- sexp && sexp.size == 2 && sexp.last&.first&.first == :string_literal
27
- end
28
21
  end
29
22
 
30
23
  def execute(*args)
data/lib/irb/cmd/help.rb CHANGED
@@ -16,6 +16,17 @@ module IRB
16
16
 
17
17
  module ExtendCommand
18
18
  class Help < Nop
19
+ class << self
20
+ def transform_args(args)
21
+ # Return a string literal as is for backward compatibility
22
+ if args.empty? || string_literal?(args)
23
+ args
24
+ else # Otherwise, consider the input as a String for convenience
25
+ args.strip.dump
26
+ end
27
+ end
28
+ end
29
+
19
30
  category "Context"
20
31
  description "Enter the mode to look up RI documents."
21
32
 
data/lib/irb/cmd/nop.rb CHANGED
@@ -26,6 +26,13 @@ module IRB
26
26
  @description = description if description
27
27
  @description
28
28
  end
29
+
30
+ private
31
+
32
+ def string_literal?(args)
33
+ sexp = Ripper.sexp(args)
34
+ sexp && sexp.size == 2 && sexp.last&.first&.first == :string_literal
35
+ end
29
36
  end
30
37
 
31
38
  if RUBY_ENGINE == "ruby" && RUBY_VERSION >= "2.7.0"
@@ -65,11 +65,6 @@ module IRB
65
65
  end
66
66
  first_line
67
67
  end
68
-
69
- def string_literal?(args)
70
- sexp = Ripper.sexp(args)
71
- sexp && sexp.size == 2 && sexp.last&.first&.first == :string_literal
72
- end
73
68
  end
74
69
 
75
70
  def execute(str = nil)
data/lib/irb/cmd/step.rb CHANGED
@@ -8,8 +8,7 @@ module IRB
8
8
  module ExtendCommand
9
9
  class Step < DebugCommand
10
10
  def execute(*args)
11
- # Run `next` first to move out of binding.irb
12
- super(pre_cmds: "next", do_cmds: ["step", *args].join(" "))
11
+ super(do_cmds: ["step", *args].join(" "))
13
12
  end
14
13
  end
15
14
  end
data/lib/irb/version.rb CHANGED
@@ -11,7 +11,7 @@
11
11
  #
12
12
 
13
13
  module IRB # :nodoc:
14
- VERSION = "1.6.0"
14
+ VERSION = "1.6.1"
15
15
  @RELEASE_VERSION = VERSION
16
- @LAST_UPDATE_DATE = "2022-11-28"
16
+ @LAST_UPDATE_DATE = "2022-12-13"
17
17
  end
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: irb
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 1.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - aycabta
8
8
  - Keiju ISHITSUKA
9
- autorequire:
9
+ autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2022-12-09 00:00:00.000000000 Z
12
+ date: 2022-12-13 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: reline
@@ -111,7 +111,7 @@ licenses:
111
111
  - Ruby
112
112
  - BSD-2-Clause
113
113
  metadata: {}
114
- post_install_message:
114
+ post_install_message:
115
115
  rdoc_options: []
116
116
  require_paths:
117
117
  - lib
@@ -126,8 +126,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
126
126
  - !ruby/object:Gem::Version
127
127
  version: '0'
128
128
  requirements: []
129
- rubygems_version: 3.3.26
130
- signing_key:
129
+ rubygems_version: 3.3.7
130
+ signing_key:
131
131
  specification_version: 4
132
132
  summary: Interactive Ruby command-line tool for REPL (Read Eval Print Loop).
133
133
  test_files: []