summaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2021-06-29Rename error_squiggle to error_highlightYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/4586
2021-06-29[WIP] add error_squiggle gemYusuke Endoh
``` $ ./local/bin/ruby -e '1.time {}' -e:1:in `<main>': undefined method `time' for 1:Integer (NoMethodError) 1.time {} ^^^^^ Did you mean? times ``` https://bugs.ruby-lang.org/issues/17930 Notes: Merged: https://github.com/ruby/ruby/pull/4586
2021-06-29Use String#include? instead of end_with? to avoid message duplicationYusuke Endoh
Previously, did_you_mean used `msg.end_with?(suggestion)` to check if its suggestion is already added. I'm now creating a gem that also modifies Exception's message. This breaks did_you_mean's duplication check. This change makes the check use String#include? instead of end_with?. https://github.com/ruby/did_you_mean/commit/b35e030549
2021-06-29Let Correctable#original_message skip prepended method definitionsYusuke Endoh
Previously, DidYouMean::Correctable#original_message did `method(:to_s).super_method.call` to call the original to_s method by skipping Correctable#to_s. I'm now creating a gem that prepends another to_s method to NameError, which confuses the hack. An immediate solution is to replace it with `method(:to_s).super_method.super_method.call` to skip the two methods. But it is too ad-hoc. This changeset uses more extensible approach and allow a prepended module to declare that they should be skipped by defining a constant named `SKIP_TO_S_FOR_SUPER_LOOKUP`. https://github.com/ruby/did_you_mean/commit/8352c154e3
2021-06-29Should require "rbconfig" to use RbConfigNobuyoshi Nakada
https://github.com/ruby/did_you_mean/commit/fbe5aaaae8
2021-06-29Start v1.6.0 developmentYuki Nishijima
https://github.com/ruby/did_you_mean/commit/3f69171813
2021-06-29Prefer qualified names under ThreadNobuyoshi Nakada
2021-06-27[ruby/irb] Optimize show_source command furtherTakashi Kokubun
https://github.com/ruby/irb/pull/249 actually slowed down how `code` is concatenated. The original way of creating `code` is faster. [before] user system total real 2.420137 0.005364 2.425501 ( 2.426264) [after] user system total real 1.000221 0.007454 1.007675 ( 1.008295) Theoretically, this implementation might skip lines that don't appear in Ripper tokens, but this assumes such lines don't impact whether the code passes compilation or not. At least normal blank lines seem to have an `on_ignored_nl` token anyway though. https://github.com/ruby/irb/commit/27dd2867cd
2021-06-27[ruby/irb] Improve performance of `show_source` for large classMasataka Pocke Kuwabara
https://github.com/ruby/irb/commit/2b79e9ad21
2021-06-25[ruby/reline] Fix missing require.Samuel Williams
https://github.com/ruby/reline/commit/010b28dfe9
2021-06-25[ruby/reline] Avoid using blocking `IO.select`.Samuel Williams
https://github.com/ruby/reline/commit/de94746393
2021-06-25Followed up 66d2fc7989d741bf5a73286233139901cecb4fc2Hiroshi SHIBATA
2021-06-25[ruby/racc] Remove Object monkey patchAaron Patterson
I don't think we need this monkey patch anymore, so lets remove it! https://github.com/ruby/racc/commit/464485e912
2021-06-25[ruby/racc] Removed needless condition for old versions of RubyGems.Hiroshi SHIBATA
https://github.com/ruby/racc/commit/fe3183b1ff
2021-06-25[ruby/racc] Drop to support Ruby 2.4Hiroshi SHIBATA
https://github.com/ruby/racc/commit/5af1a42a3b
2021-06-25[ruby/racc] Followed up #162Hiroshi SHIBATA
https://github.com/ruby/racc/commit/d66cd12166
2021-06-25[ruby/racc] Stop compressing integer listsJean Boussier
It is unclear why this was implemented, I assume it was for performance back in 2006. However today, this compression defeats bytecode caching entirely and end up being counter productive. https://github.com/ruby/racc/commit/ae3703c1d0
2021-06-24Remove also debug symbol directory at clean on macOSNobuyoshi Nakada
2021-06-24Prefer configured command as RM_RFNobuyoshi Nakada
2021-06-23[ruby/rdoc] Specify working directory for RDoc::Options#check_filesHiroshi SHIBATA
https://github.com/ruby/rdoc/commit/f6cca9bd2f
2021-06-22[ruby/irb] Sort ls result ordered by anscestryKeiko Kaneko
https://github.com/ruby/irb/commit/fdd5c0a71e
2021-06-21Rescue conversion error of inputrcaycabta
2021-06-21Check Ruby version to use Fiddle with variadic args in test-allaycabta
2021-06-21[ruby/irb] Improve stackprof measureUlysse Buonomo
Allow usage of more detailed args when setting stackprof callback. Signed-off-by: Ulysse Buonomo <buonomo.ulysse@gmail.com> https://github.com/ruby/irb/commit/c9d101f450
2021-06-21[ruby/reline] Version 0.2.6aycabta
https://github.com/ruby/reline/commit/5917e3a337
2021-06-21[ruby/reline] Fix explamation of #read_ioaycabta
https://github.com/ruby/reline/commit/301ed11bec
2021-06-21[ruby/reline] Remove FIXME comment in #renderaycabta
https://github.com/ruby/reline/commit/acd8f8efbb
2021-06-21[ruby/reline] Remove TODO comment in #render_partialaycabta
https://github.com/ruby/reline/commit/bb6ea232c2
2021-06-21[ruby/reline] Add binding C-x C-x to em_exchange_mark on Windowsaycabta
https://github.com/ruby/reline/commit/24a2489b62
2021-06-21[ruby/reline] Treat C-Space as M-Space on Windowsaycabta
https://github.com/ruby/reline/commit/69beca2863
2021-06-21[ruby/reline] Check existance of a constant, Fiddle::VERSIONaycabta
https://github.com/ruby/reline/commit/4b74c3d83a
2021-06-21[ruby/reline] Add Meta+arrow-keys in extended entries of terminfoaycabta
https://github.com/ruby/reline/commit/af6f6ed088
2021-06-21[ruby/reline] Terminfo.tigetstr should be able to receive tiparm in method chainaycabta
https://github.com/ruby/reline/commit/4a3e308163
2021-06-21[ruby/reline] Terminfo.tigetstr and tiparm should return String objectaycabta
https://github.com/ruby/reline/commit/1e287d10cc
2021-06-21[ruby/reline] Add terminfo supportaycabta
https://github.com/ruby/reline/commit/74a7ffaa2f
2021-06-21[ruby/reline] Handle Errno::ENOTTY correctlyaycabta
https://github.com/ruby/reline/commit/8daa392ba6
2021-06-21[ruby/reline] Fix Reline::Unicode.calculate_width when input is not a TTYJeremy Evans
This fixes an error when output is redirected: ``` $ run_ruby -rreline -e '$stderr.puts Reline::Unicode.calculate_width("\u221a").inspect' </dev/null >/dev/null /home/jeremy/tmp/ruby/lib/reline/ansi.rb:189:in `raw': Operation not supported by device (Errno::ENODEV) ``` The @@encoding -> defined?(@@encoding) changes is necessary because without that part of the commit, the following error would be raised by the above command: ``` /home/jeremy/tmp/reline/lib/reline/general_io.rb:10:in `encoding': uninitialized class variable @@encoding in Reline::GeneralIO (NameError) ``` Problem reported and initial patch for Windows provided by Richard Sharman. I tested this only on OpenBSD, but hopefully it works for other operating systems. Fixes [Bug #17493] https://github.com/ruby/reline/commit/c001971bb3
2021-06-21[ruby/reline] Treat return key correctly on Windowsaycabta
To fix Reline::TestRendering#test_binding_for_vi_movement_mode. https://github.com/ruby/reline/commit/0df3d2a1dc
2021-06-21[ruby/reline] The config file must accept any character encodingaycabta
In Japan, so many programmers used EUC-JP to write text files that contain Japanese. Many .inputrc files which contain EUC-JP are still being copied and used. This commit supports the whole encoding of what user set including UTF-8. ref. https://github.com/ruby/reline/pull/280 https://github.com/ruby/reline/commit/0b45022e16
2021-06-21[ruby/reline] Use ReadConsoleInputW() instead of getwch()aycabta
This needs https://github.com/aycabta/yamatanooroti/pull/19, which is released by yamatanooroti gem 0.0.7, to test with yamatanooroti. https://github.com/ruby/reline/commit/06c1f45da1
2021-06-21[ruby/reline] ensure reline's encoding is used when reading inputrc ↵Mark Delk
character values This change ensures we use `Reline::IOGate`'s `encoding` when converting characters from their integer values. This fixes an issue that may occur if you have UTF characters in your `.inputrc`, but your default encoding isn't set. For example: ``` > 127864.ord.chr RangeError: 127864 out of char range from (pry):1:in `chr' > Reline::IOGate.encoding => #<Encoding:UTF-8> > 127864.ord.chr(Reline::IOGate.encoding) => "🍸" ``` https://github.com/ruby/reline/commit/cf372fc0fc
2021-06-21[ruby/irb] Version 1.3.6aycabta
https://github.com/ruby/irb/commit/75aa8d159b
2021-06-16[ruby/net-protocol] Get rid of `__send__`Nobuyoshi Nakada
Mitigate the security risk: https://devcraft.io/2021/01/07/universal-deserialisation-gadget-for-ruby-2-x-3-x.html https://github.com/ruby/net-protocol/commit/a9970437e8
2021-06-15[ruby/ostruct] v0.4.0Marc-Andre Lafortune
https://github.com/ruby/ostruct/commit/8534f69e4e
2021-06-14[lib/ostruct] Allow overriding of `block_given?`Marc-Andre Lafortune
Notes: Merged: https://github.com/ruby/ruby/pull/4572
2021-06-14[ruby/ostruct] bump upNobuyoshi Nakada
https://github.com/ruby/ostruct/commit/bb253be3e9
2021-06-14Add fallback block to `OpenStruct#delete_field` (#1409)jfrazx
Notes: Merged-By: marcandre <github@marc-andre.ca>
2021-06-02[ruby/rdoc] Add a dependency on psych gem 4.0.0 or neweraycabta
https://github.com/ruby/rdoc/commit/ebe185c877
2021-05-31[ruby/net-protocol] Bump version to 0.1.1Hiroshi SHIBATA
https://github.com/ruby/net-protocol/commit/97c4b68528
2021-05-28[rubygems/rubygems] Copy files specific to testing rubygems to `test`David Rodríguez
https://github.com/rubygems/rubygems/commit/aa390a3500