summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* [ruby/irb] Simplify Locale#loadStan Lo2023-04-271-39/+2
| | | | | | | | | | | | | (https://github.com/ruby/irb/pull/571) * Simplify Locale#load Instead of loading file content with `MagicFile` and then evaluting it, we can just use `Kernel.load` to load the file. * Remove unused optional argument * Remove unused Locale#require and #toplevel_load
* [ruby/irb] Stop using MagicFile for printing help messagesStan Lo2023-04-271-1/+1
| | | | | | | | | | | | | (https://github.com/ruby/irb/pull/573) `MagicFile` was introduced around v0.9.6, which was like 14~15 years ago. It was needed because back then we needed to read a file's magic comment to determine the encoding of it, and read it with that encoding. Commit: https://github.com/ruby/irb/commit/3ee79e89adb8e21b63d796e53bcc86281685076d But now both EN and JA's help-message file are UTF-8 and have removed the encoding comment, we don't need to open them with `MagicFile` anymore.
* RJIT: Fix unspecified_bits with localsTakashi Kokubun2023-04-261-2/+2
|
* [ruby/irb] Remove encoding_aliases.rbStan Lo2023-04-262-16/+6
| | | | | | | | (https://github.com/ruby/irb/pull/569) We don't have to load another file to define the legacy encoding aliases map because there's only one definition of it. We can define it in locale.rb directly.
* [ruby/irb] Fix Locale's encoding lookup for Japanese encodingsStan Lo2023-04-261-1/+2
| | | | | | | | | | | | | | (https://github.com/ruby/irb/pull/568) In https://github.com/ruby/irb/commit/3ee79e89adb8e21b63d796e53bcc86281685076d, `encoding_aliases.rb` was introduced to return the correct encoding object for `ujis` and `euc` encodings. However, the return value of `@@legacy_encoding_alias_map[@encoding_name]` is always overridden by a second look up with `Encoding.find(@encoding_name)`. So the logic didn't work as expected. This commit fixes the problem.
* [ruby/syntax_suggest] Clean up outputschneems2023-04-252-21/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I previously left a comment stating I didn't know why a certain method existed. In investigating the code in `CaptureCodeContext#capture_before_after_kws` I found that it was added as to give a slightly less noisy output. The docs for AroundBlockScan#capture_neighbor_context only describe keywords as being a primary concern. I modified that code to only include lines that are keywords or ends. This reduces the output noise even more. This allows me to remove that `start_at_next_line` method. One weird side effect of the prior logic is it would cause this code to produce this output: ``` class OH def hello def hai end end ``` ``` 1 class OH > 2 def hello 4 def hai 5 end 6 end ``` But this code to produce this output: ``` class OH def hello def hai end end ``` ``` 1 class OH > 2 def hello 4 end 5 end ``` Note the missing `def hai`. The only difference between them is that space. With this change, they're now both consistent. https://github.com/ruby/syntax_suggest/commit/4a54767a3e
* [ruby/set] Update lib/set.rbAkinori MUSHA2023-04-251-1/+0
| | | | https://github.com/ruby/set/commit/bc59f85f2f
* [ruby/set] Expose Set::VERSIONHiroshi SHIBATA2023-04-252-2/+12
| | | | https://github.com/ruby/set/commit/d39b33f463
* [ruby/abbrev] Update lib/abbrev.rbAkinori MUSHA2023-04-251-1/+0
| | | | https://github.com/ruby/abbrev/commit/6fa790eac1
* [ruby/abbrev] Expose Abbrev::VERSIONHiroshi SHIBATA2023-04-252-2/+11
| | | | https://github.com/ruby/abbrev/commit/255ca681c3
* [ruby/reline] Revert #335 (Trap TSTP to handle C-z)Carl Brasic2023-04-241-11/+0
| | | | | | | | | | | | | | | | | | | (https://github.com/ruby/reline/pull/535) This PR was an effort to address #321 (ed_quoted_insert doesn't work properly) but per the reporter it did not work correctly. Moreover, it introduced a major regression: Shell job control stopped working in all applications that use reline, notably IRB. Bash and other shells send SIGTSTP in response to C-z to implement job suspension. Handling SIGSTP opts out of this functionality. For a line oriented terminal program this should be avoided (not to mention, this behavior diverges from readline's) https://github.com/ruby/reline/commit/26383d25b8 Co-authored-by: Carl Brasic <cbrasic@drwholdings.com>
* [ruby/irb] Simplify the help command's implementationStan Lo2023-04-241-14/+12
| | | | | | | | | | | | (https://github.com/ruby/irb/pull/564) The current method-redefining approach brings little benefit, makes it harder to understand the code, and causes warnings like: > warning: method redefined; discarding old execute This patch simplifies it while displaying more helpful message when rdoc couldn't be loaded.
* [ruby/irb] Filter out top-level methods when using `lsStan Lo2023-04-241-2/+5
| | | | | | | | | <Class/Module>` (https://github.com/ruby/irb/pull/562) Instead of always printing methods inherited from Class or Module, IRB by default should filter them out unless `<Class/Module>` is specified to be either of those.
* [ruby/irb] fix typo in tracer (https://github.com/ruby/irb/pull/565)Yusuf Daniju2023-04-231-1/+1
| | | | https://github.com/ruby/irb/commit/2f567f3d3e
* [ruby/rinda] Expose Rinda::VERSIONHiroshi SHIBATA2023-04-212-2/+11
| | | | https://github.com/ruby/rinda/commit/fa3865ac48
* [rubygems/rubygems] util/rubocop -AHiroshi SHIBATA2023-04-201-1/+1
| | | | https://github.com/rubygems/rubygems/commit/784e5e2fe5
* [rubygems/rubygems] Support Symbol and URL keysHiroshi SHIBATA2023-04-201-1/+1
| | | | https://github.com/rubygems/rubygems/commit/3bda049c73
* [rubygems/rubygems] warn message when RubyGems handle invalid yaml like ↵Hiroshi SHIBATA2023-04-201-1/+7
| | | | | | 'invalid: foo: bar' https://github.com/rubygems/rubygems/commit/b8d0c25b7e
* Hide Gem::MockGemUi. It's only used by testsHiroshi SHIBATA2023-04-191-86/+0
|
* [rubygems/rubygems] To use Gem::YAMLSerializer in BundlerHiroshi SHIBATA2023-04-191-4/+11
| | | | https://github.com/rubygems/rubygems/commit/5351e01b32
* [rubygems/rubygems] Copy YAMLSerializer from BundlerHiroshi SHIBATA2023-04-192-4/+93
| | | | https://github.com/rubygems/rubygems/commit/6a97346708
* [rubygems/rubygems] Bundler::YAMLSerializer.load couldn't raise error when ↵Hiroshi SHIBATA2023-04-191-33/+28
| | | | | | invalid yaml was provided https://github.com/rubygems/rubygems/commit/cfcfde04c7
* [rubygems/rubygems] Introduce self.load_with_rubygems_config_hashHiroshi SHIBATA2023-04-192-39/+37
| | | | https://github.com/rubygems/rubygems/commit/9175b8cf2a
* [rubygems/rubygems] Introduce self.dump_with_rubygems_yamlHiroshi SHIBATA2023-04-191-13/+11
| | | | https://github.com/rubygems/rubygems/commit/3d3b0d80a1
* [rubygems/rubygems] Removed trailing-slash for domainHiroshi SHIBATA2023-04-191-3/+3
| | | | https://github.com/rubygems/rubygems/commit/81ba58f445
* [rubygems/rubygems] Wrap self.convert_rubygems_config_hash from ↵Hiroshi SHIBATA2023-04-192-34/+41
| | | | | | Bundler::YAMLSerializer.load https://github.com/rubygems/rubygems/commit/080880ac23
* [rubygems/rubygems] Move all changes only in RubyGemsHiroshi SHIBATA2023-04-193-25/+42
| | | | https://github.com/rubygems/rubygems/commit/d842e2092f
* [rubygems/rubygems] Added guard condition for replacing __ variable in YAML keysHiroshi SHIBATA2023-04-192-15/+3
| | | | https://github.com/rubygems/rubygems/commit/e7d31405ea
* [rubygems/rubygems] Keep compatiblity of Bundler specsHiroshi SHIBATA2023-04-193-20/+23
| | | | https://github.com/rubygems/rubygems/commit/b211eeacba
* [rubygems/rubygems] Replaced empty hash to nil value in YAMLHiroshi SHIBATA2023-04-191-0/+15
| | | | https://github.com/rubygems/rubygems/commit/8771fbf53d
* [rubygems/rubygems] Only convert old URL key name when it's contained double ↵Hiroshi SHIBATA2023-04-191-1/+1
| | | | | | underscore https://github.com/rubygems/rubygems/commit/a4bfa2ef94
* [rubygems/rubygems] Added missing require for Bundler::YAMLSerializerHiroshi SHIBATA2023-04-191-0/+1
| | | | https://github.com/rubygems/rubygems/commit/55ef32fdd7
* [rubygems/rubygems] Fix regexp for SymbolHiroshi SHIBATA2023-04-191-1/+1
| | | | https://github.com/rubygems/rubygems/commit/9a3ed682a0
* [rubygems/rubygems] Don't use PsychHiroshi SHIBATA2023-04-191-3/+2
| | | | https://github.com/rubygems/rubygems/commit/d6555aaa28
* [rubygems/rubygems] Added explicitly loading for Gem::SafeYAMLHiroshi SHIBATA2023-04-191-0/+2
| | | | https://github.com/rubygems/rubygems/commit/3d9d587dd7
* [rubygems/rubygems] We need to convert empty string for nil valueHiroshi SHIBATA2023-04-191-0/+2
| | | | https://github.com/rubygems/rubygems/commit/348c82311f
* [rubygems/rubygems] Handle Symbol valueHiroshi SHIBATA2023-04-191-1/+3
| | | | https://github.com/rubygems/rubygems/commit/c98677d073
* [rubygems/rubygems] Handle Symbol key and Interger and Boolean valuesHiroshi SHIBATA2023-04-191-3/+18
| | | | https://github.com/rubygems/rubygems/commit/63efdac045
* [rubygems/rubygems] Try to use pure-ruby YAML serializer for configurationHiroshi SHIBATA2023-04-191-6/+5
| | | | https://github.com/rubygems/rubygems/commit/3268d40974
* Update RJIT to support newarray_sendAaron Patterson2023-04-181-3/+66
| | | | This also adds max / hash support
* [ruby/reline] Change Reline.add_dialog_proc(name, nil) to properlytomoya ishida2023-04-151-2/+6
| | | | | | | remove dialog_proc (https://github.com/ruby/reline/pull/532) https://github.com/ruby/reline/commit/43283b2f37
* [ruby/prettyprint] Expose PrettyPrint::VERSIONHiroshi SHIBATA2023-04-142-2/+11
| | | | https://github.com/ruby/prettyprint/commit/c6f3947e96
* [ruby/pp] Expose PP::VERSIONHiroshi SHIBATA2023-04-142-2/+12
| | | | https://github.com/ruby/pp/commit/3d0e65e79f
* [ruby/resolv] Expose Resolv::VERSIONHiroshi SHIBATA2023-04-142-2/+11
| | | | https://github.com/ruby/resolv/commit/6ab2385e89
* [ruby/securerandom] Expose SecureRandom::VERSIONHiroshi SHIBATA2023-04-142-2/+12
| | | | https://github.com/ruby/securerandom/commit/2e6434331d
* avoid seeding卜部昌平2023-04-131-11/+0
| | | | | | | | | | | | | OpenSSL's man page previously stated that "the application is responsible for seeding the PRNG by calling RAND_add" (see [1]). So we had this code. However things changed. They no longer say so, instead "manual (re-)seeding of the default OpenSSL random generator is not necessary" now (see [2]). It seems all OpenSSL versions that we support now already behaves like this. Let's follow that. [1]: https://www.openssl.org/docs/man1.0.2/man3/RAND_add.html [2]: https://www.openssl.org/docs/manmaster/man3/RAND_add.html
* [ruby/time] Expose Time::VERSIONHiroshi SHIBATA2023-04-132-2/+12
| | | | https://github.com/ruby/time/commit/32793b56b7
* [ruby/time] Bump version to 0.2.2Hiroshi SHIBATA2023-04-131-1/+1
| | | | https://github.com/ruby/time/commit/5f080cf700
* [ruby/tempfile] Expose Tempfile::VERSIONHiroshi SHIBATA2023-04-132-2/+11
| | | | https://github.com/ruby/tempfile/commit/6aa1f37dc4
* [ruby/shellwords] Expose Shellwords::VERSIONHiroshi SHIBATA2023-04-132-2/+13
| | | | https://github.com/ruby/shellwords/commit/e38b8b026a