summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-02-22[Feature #18249] Include ruby.h in extensions to have ABI versionPeter Zhu
All shared libraries must have `include/ruby/internal/abi.h` to include the ABI version. Including `ruby.h` will guarantee that. Notes: Merged: https://github.com/ruby/ruby/pull/5474
2022-02-22[Feature #18249] Implement ABI checkingPeter Zhu
Header file include/ruby/internal/abi.h contains RUBY_ABI_VERSION which is the ABI version. This value should be bumped whenever an ABI incompatible change is introduced. When loading dynamic libraries, Ruby will compare its own `ruby_abi_version` and the `ruby_abi_version` of the loaded library. If these two values don't match it will raise a `LoadError`. This feature can also be turned off by setting the environment variable `RUBY_RUBY_ABI_CHECK=0`. This feature will prevent cases where previously installed native gems fail in unexpected ways due to incompatibility of changes in header files. This will force the developer to recompile their gems to use the same header files as the built Ruby. In Ruby, the ABI version is exposed through `RbConfig::CONFIG["ruby_abi_version"]`. Notes: Merged: https://github.com/ruby/ruby/pull/5474
2022-02-22[ruby/reline] Fix support for emacs-ctlx and emacs-meta keymapsTim Pope
The existing implementation, given the below .inputrc, erroneously creates a "C-v" key binding: set keymap emacs-ctlx "\C-v": "[C-x C-v was pressed]" This fixes it to instead create a "C-x C-v" keybinding. https://github.com/ruby/reline/commit/719f52d231
2022-02-22[ruby/zlib] [DOC] Fix typo in Zlib.adler32_combineMau Magnaguagno
https://github.com/ruby/zlib/commit/5e8f0b4164
2022-02-22[ruby/rdoc] Prefer `require 'cgi/util'` instead of `require 'cgi'`Yusuke Endoh
RDoc is using only CGI.escape, escapeHTML, and unescape. We don't have to load the whole source code of cgi gem. https://github.com/ruby/rdoc/commit/d096222cc2
2022-02-22[rubygems/rubygems] Resolve cleaned-up error with temporary gemhomeHiroshi SHIBATA
https://github.com/rubygems/rubygems/commit/623162ad2b
2022-02-22* 2022-02-22 [ci skip]git
2022-02-22Factor a "highlight" symbol outYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22Remove unneeded newline from detailed_messageYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22Add a test for Exception#detailed_messageYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22Let Exception#full_message pass highlight keywords to #detailed_messageYusuke Endoh
.. even when the argument is not explicitly passed. Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22test/ruby/test_rubyoptions.rb: Make it pass on WindowsYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22The default highlight arguments of Exception#detailed_message is falseYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22Exception#detailed_message is addedYusuke Endoh
Also, the default error printer and Exception#full_message use the method instead of `Exception#message` to get the message string. `Exception#detailed_message` calls `Exception#message`, decorates and returns the result. It adds some escape sequences to highlight, and the class name of the exception to the end of the first line of the message. [Feature #18370] Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22Refactor out rb_decorate_message from print_errinfoYusuke Endoh
rb_decorate_message adds bold escape sequences to message, and the class name of exception (like " (RuntimeError)) of "message (RuntimeError)"). Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22Do not escape error messageYusuke Endoh
[Feature #18367] Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-22error.c: RefactoringYusuke Endoh
Factor out from rb_error_write the responsibility to check if stderr is a tty. Notes: Merged: https://github.com/ruby/ruby/pull/5516
2022-02-21Removed dependency of net-protocol. There is no plan to remove from stdlibHiroshi SHIBATA
2022-02-21Removed dependency of io-wait. There is no plan to remove from stdlibHiroshi SHIBATA
2022-02-21rb_debug_rstring_null_ptr: add newlines in the message [ci skip]Nobuyoshi Nakada
The message should end with a newline, and break the long paragraph.
2022-02-21[DOC] Set the documentation title and main pageNobuyoshi Nakada
Copied from https://github.com/ruby/docs.ruby-lang.org/ to be as same as docs.ruby-lang.org.
2022-02-21* 2022-02-21 [ci skip]git
2022-02-21Fix links [ci skip]Kazuhiro NISHIYAMA
2022-02-20* 2022-02-20 [ci skip]git
2022-02-20[MSWin] Tentative measure for a bug of VS2022 [Misc #18362]Nobuyoshi Nakada
Disable the use of `__assume()`, when combinations of `isnan()`, `isinf()` and `__assume()` will be wrongly optimized due to the bug of VS2022. Notes: Merged: https://github.com/ruby/ruby/pull/5579
2022-02-20[MSWin] Try VS2022Nobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/5579
2022-02-20[MSWin] Reduce duplicate configurationsNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/5579
2022-02-19Check if `__assume` is supportedNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/5577
2022-02-19Define `HAVE___BUILTIN_UNREACHABLE` instead of `UNREACHABLE`Nobuyoshi Nakada
`UNREACHABLE` in ruby/internal/has/builtin.h is only used as just a flag now, and redefined in ruby/backward/2/assume.h then. Notes: Merged: https://github.com/ruby/ruby/pull/5577
2022-02-19Replace and Using METACLASS_OF macroS-H-GAMELINKS
Notes: Merged: https://github.com/ruby/ruby/pull/5576
2022-02-19Add String#byteindex, String#byterindex, and MatchData#byteoffset (#5518)Shugo Maeda
* Add String#byteindex, String#byterindex, and MatchData#byteoffset [Feature #13110] Co-authored-by: NARUSE, Yui <naruse@airemix.jp> Notes: Merged-By: shugo <shugo@ruby-lang.org>
2022-02-19Find pattern is no longer experimental [Feature #18585]Kazuki Tsujimoto
2022-02-19Fix location of NODE_LIT in p_kwKazuki Tsujimoto
2022-02-19Use symbols for clock IDs if `clockid_t` is not numericNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/5574
2022-02-19Set static IDs to same name variablesNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/5574
2022-02-19RUBY_REPLACE_TYPE: check if the target type is a pointerNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/5574
2022-02-19[DOC] prefer rdoc references over generated URLsNobuyoshi Nakada
2022-02-18Enhanced RDoc for io.c (#5573)Burdette Lamar
Links to options doc added/improved; in particular, new links to new section "Encoding Options" in encoding.rdoc. Minor inconsistencies ironed out. Notes: Merged-By: BurdetteLamar <BurdetteLamar@Yahoo.com>
2022-02-19* 2022-02-19 [ci skip]git
2022-02-18New doc about encoding (#5572)Burdette Lamar
This is the beginning of an extended explication of Ruby encoding. One of its more important jobs is to provide link targets for encoding documentation in other classes (String, File, IO, etc.). In particular, they can link to the "Encoding Options" section. I'll have much to add to this document going forward, along with suitable adjustments in the class documentation. Notes: Merged-By: BurdetteLamar <BurdetteLamar@Yahoo.com>
2022-02-18Remove unused function declaration in dln.cPeter Zhu
getenv is no longer used in dln.c.
2022-02-18LONG2NUM() should be used for rmatch_offset::{beg,end}Shugo Maeda
https://github.com/ruby/ruby/pull/5518#discussion_r809645406
2022-02-18Enhanced RDoc concerning command injection (#5537)Burdette Lamar
Clarifies security vulnerabilities for commands. Treats: Kernel.system Kernel.` (backtick) IO.popen IO.read IO.write IO.binread IO.binwrite IO.readlines IO.foreach Notes: Merged-By: BurdetteLamar <BurdetteLamar@Yahoo.com>
2022-02-18gen-mail.rb: support markdown file pathNARUSE, Yui
2022-02-18[wasm] vm.c: stop unwinding to main for every vm_exec call by setjmpYuta Saito
the original rb_wasm_setjmp implementation always unwinds to the root call frame to have setjmp compatible interface, and simulate sjlj's undefined behavior. Therefore, every vm_exec call unwinds to main, and a deep call stack makes setjmp call very expensive. The following snippet from optcarrot takes 5s even though it takes less than 0.3s on native. ``` [0x0, 0x4, 0x8, 0xc].map do |attr| (0..7).map do |j| (0...0x10000).map do |i| clr = i[15 - j] * 2 + i[7 - j] clr != 0 ? attr | clr : 0 end end end ``` This patch adds a WASI specialized vm_exec which uses lightweight try-catch API without unwinding to the root frame. After this patch, the above snippet takes only 0.5s. Notes: Merged: https://github.com/ruby/ruby/pull/5502
2022-02-18Mention Set as a new builtin class to NEWSAkinori MUSHA
Notes: Merged: https://github.com/ruby/ruby/pull/5563
2022-02-18Make Set a builtin feature [Feature #16989]Akinori MUSHA
Notes: Merged: https://github.com/ruby/ruby/pull/5563
2022-02-18* 2022-02-18 [ci skip]git
2022-02-17Add Thread.each_caller_locationJeremy Evans
This method takes a block and yields Thread::Backtrace::Location objects to the block. It does not take arguments, and always starts at the default frame that caller_locations would start at. Implements [Feature #16663] Notes: Merged: https://github.com/ruby/ruby/pull/5445
2022-02-17Do not search for commands with double tool prefixes [Bug #18504]Nobuyoshi Nakada
The `CC` found by `AC_CHECK_TOOL` is prefixed by the host triplet when cross compiling. To search for commands with `AC_CHECK_TOOL` based on that `CC` means to search also doubly prefixed names. Notes: Merged: https://github.com/ruby/ruby/pull/5565