| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|
|
|
| |
IRB::ReadlineInputMethod#initialize changes them via IRB.set_encoding.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It caches a path to .irbrc file, which has caused random failure:
```
1) Failure:
TestIRB::ExtendCommand#test_irb_info_multiline [/home/mame/work/ruby/test/irb/test_cmd.rb:49]:
Expected /
Ruby\sversion: .+\n
IRB\sversion:\sirb .+\n
InputMethod:\sReidlineInputMethod\swith\sReline .+ and .+\n
\.irbrc\spath: .+
/x to match "Ruby version: 2.8.0\n" +
"IRB version: irb 1.2.3 (2020-02-15)\n" +
"InputMethod: ReidlineInputMethod with Reline 0.1.4 and /tmp/test_reline_config_155659/.inputrc\n".
```
|
|
|
|
| |
IRB::ReadlineInputMethod#initialize sets via IRB.set_encoding.
|
| |
|
|
|
|
|
| |
Readline::VERSION may not be a single word, e.g EditLine wrapper
when linked with editline.
|
|
|
|
| |
https://github.com/ruby/irb/commit/cdbb9dfc9f
|
|
|
|
| |
https://github.com/ruby/irb/commit/a6fe58e916
|
|
|
|
| |
https://github.com/ruby/irb/commit/13572d8cdc
|
| |
|
|
|
|
| |
https://github.com/ruby/irb/commit/dbc7b059c7
|
|
|
|
| |
https://github.com/ruby/irb/commit/6184b227ad
|
| |
|
|
|
|
|
|
| |
The previous version of the test method used a symbol, ":abcdefg" to complete
but longer symbols that can be completed are defined by other test methods of
other libs.
|
|
|
|
| |
This reverts commit 3af3431c2c145134996e66f3d8d9ade8ad81bde0.
|
|
|
|
|
|
|
|
|
|
|
|
| |
A closed brace in auto-indent shouldn't affect the next brace in the same line,
but it behaves like below:
p() {
}
It's a bug.
https://github.com/ruby/irb/commit/fbe59e344f
|
|
|
|
|
|
|
| |
IRB::InputCompletor::PerfectMatchedProc crashes when doc not found because a
variable name was incorrect.
https://github.com/ruby/irb/commit/889fd4928f
|
|
|
|
| |
https://github.com/ruby/irb/commit/dbbf086c1f
|
|
|
|
| |
https://github.com/ruby/irb/commit/9eb1801a66
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
https://github.com/ruby/irb/issues/55
If we had put multiple open braces on a line the with no closing brace
spaces_of_nest array keeps getting '0' added to it. This means that when
we pop off of this array we are saying that we should be in position zero
for the next line. This is an issue because we don't always want to be
in position 0 after a closing brace.
Example:
```
[[[
]
]
]
```
In the above example the 'spaces_of_nest' array looks like this after
the first line is entered: [0,0,0]. We really want to be indented 4
spaces for the 1st closing brace 2 for the 2nd and 0 for the 3rd. i.e.
we want it to be: [0,2,4].
We also saw this issue with a heredoc inside of an array.
```
[<<FOO]
hello
FOO
```
https://github.com/ruby/irb/commit/80c69c8272
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit fixes the check_newline_depth_difference method to multiple
open braces on one line into account. Before this change we were
subtracting from the depth in check_newline_depth_difference on
every open brace. This is the right thing to do if the opening and
closing brace are on the same line. For example in a method definition we
have an opening and closing parentheses we want to add 1 to our depth,
and then remove it.
```
def foo()
end
```
However this isn't the correct behavior when the brace spans multiple
lines. If a brace spans multiple lines we don't want to subtract from
check_newline_depth_difference and we want to treat the braces the same
way as we do `end` and allow check_corresponding_token_depth to pop the
correct depth.
Example of bad behavior:
```
def foo()
[
]
puts 'bar'
end
```
Example of desired behavior:
```
def foo()
[
]
puts 'bar'
end
```
https://github.com/ruby/irb/commit/7dc8af01e0
|
| |
|
|
|
|
| |
https://github.com/ruby/irb/commit/1f3a84ab6b
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The set_auto_indent method calculates the correct number of spaces for
indenting a line. We think there might be a few bugs in this method so
we are testing the current functionality to make sure nothing breaks
when we address those bugs.
Example test failure:
```
1) Failure:
TestIRB::TestRubyLex#test_auto_indent [/Users/Ben/Projects/irb/test/irb/test_ruby_lex.rb:75]:
Calculated the wrong number of spaces for:
def each_top_level_statement
initialize_input
catch(:TERM_INPUT) do
loop do
begin
prompt
unless l = lex
throw :TERM_INPUT if @line == ''
else
.
<10> expected but was
<12>.
```
https://github.com/ruby/irb/commit/752d5597ab
|
|
|
|
| |
https://github.com/ruby/irb/commit/236590882c
|
| |
|
|
|
|
|
|
| |
IRB completion logic always needed exponential notation for complex literal
such as 3e6i but it's bug. I fixed to support complex literal without
exponential notation such as 3i.
|
| |
|
| |
|
|
|
|
| |
Co-authored-by: Kazuhiro NISHIYAMA <zn@mbf.nifty.com>
|
| |
|
| |
|
|
|
|
| |
like pry
|
|
|
| |
[Bug #16250]
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
This reverts commit 1ee88c51b3c319b74b69540e111e4a1c24833cad.
|
| |
|
| |
|
|
|
|
|
|
| |
Upgrade IRB to https://github.com/ruby/irb/commit/41ea43a4a732e094acfa1b0fc1473fdcda9e6227
Mostly backport changes.
|
| |
|
| |
|
|
|
|
| |
in de541fe1961370e64541d73c96cf790d30f28604 :bow:
|
|
|
|
|
| |
Actually de541fe1961370e64541d73c96cf790d30f28604 was still needed.
This commit would improve the test coverage using the branch.
|
|
|
|
|
| |
This was needed before 0c459af7c233adb5f44022350bfe8fa132d8053e but it
could be actually useless now. But I added this anyway just in case.
|
|
|
|
|
|
| |
* lib/irb/color.rb (IRB::Color.scan): ignore "incomplete end of
input" error only, to colorize invalid characters, e.g., control
characters, and invalid symbols, as errors.
|